-Wodr: C++ One Definition Rule violations in Firefox
Categories
(Firefox Build System :: General: Unsupported Platforms, defect, P5)
Tracking
(Not tracked)
People
(Reporter: jh, Unassigned)
References
Details
Attachments
(2 files)
Comment 1•6 years ago
|
||
Updated•6 years ago
|
Reporter | ||
Comment 2•6 years ago
|
||
Updated•6 years ago
|
Updated•6 years ago
|
Comment 3•5 years ago
|
||
Hi! I am new here, how can I do to build Firefox with GCC 8 and LTO to replicate the warning?
Updated•2 years ago
|
Comment 4•8 months ago
|
||
This is still reproducible, there are also some lto type mismatch warnings. see the attached log for more info.
Note that these issues exist with Clang too, it's just that Clang doesn't diagnose them (doesn't have -Wodr or -Wlto-type-mismatch right now, I've filed bugs asking for them to support it).
Updated•4 months ago
|
Comment 6•4 months ago
|
||
(Note that clang does have -Wodr
but this flag really makes sense when merging compilation unit)
(In reply to Sam James from comment #5)
Note that these issues exist with Clang too, it's just that Clang doesn't diagnose them (doesn't have -Wodr or -Wlto-type-mismatch right now, I've filed bugs asking for them to support it).
See https://github.com/llvm/llvm-project/issues/34914 (maskray also covers it on his blog at https://maskray.me/blog/2022-11-13-odr-violation-detection, but tl;dr is "only asan or C++ modules" and https://github.com/llvm/llvm-project/issues/56487.
Thank you for taking a look Serge!
Description
•