Compilation fails with the following message, possibly a GCC bug. This is not the first version of Firefox with this problem, but the problem is still recent - according to emerge.log it was probably introduced in 91.8.0. Compilation with set clang USE-flag succeeds. 1:30.72 /var/tmp/portage/www-client/firefox-91.10.0/work/firefox-91.10.0/dom/base/nsTreeSanitizer.cpp:635:20: error: non-constant condition for static assertion 1:30.72 635 | static_assert(AllOf(std::begin(kURLAttributesSVG), std::end(kURLAttributesSVG), 1:30.72 | ~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 1:30.72 636 | [](auto aURLAttributeSVG) { 1:30.72 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~ 1:30.72 637 | return AnyOf(std::begin(kAttributesSVG), 1:30.72 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 1:30.72 638 | std::end(kAttributesSVG), 1:30.72 | ~~~~~~~~~~~~~~~~~~~~~~~~~ 1:30.72 639 | [&](auto aAttributeSVG) { 1:30.72 | ~~~~~~~~~~~~~~~~~~~~~~~~~ 1:30.72 640 | return aAttributeSVG == aURLAttributeSVG; 1:30.72 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 1:30.72 641 | }); 1:30.72 | ~~~ 1:30.72 642 | })); 1:30.72 | ~~ 1:30.72 /var/tmp/portage/www-client/firefox-91.10.0/work/firefox-91.10.0/dom/base/nsTreeSanitizer.cpp:635:20: in 'constexpr' expansion of 'mozilla::AllOf<const nsStaticAtom* const*, <lambda(auto:30)> >(std::begin<const nsStaticAtom* const, 2>(kURLAttributesSVG), std::end<const nsStaticAtom* const, 2>(kURLAttributesSVG), (<lambda closure object><lambda(auto:30)>{}, <lambda(auto:30)>()))' 1:30.72 /var/tmp/portage/www-client/firefox-91.10.0/work/firefox_build/dist/include/mozilla/Algorithm.h:24:15: in 'constexpr' expansion of 'aPred.<lambda(auto:30)>(((const nsStaticAtom*)(* aFirst)))' 1:30.72 /var/tmp/portage/www-client/firefox-91.10.0/work/firefox-91.10.0/dom/base/nsTreeSanitizer.cpp:637:35: in 'constexpr' expansion of 'mozilla::AnyOf<const nsStaticAtom* const*, <lambda(auto:30)>::<lambda(auto:31)> >(std::begin<const nsStaticAtom* const, 182>(kAttributesSVG), std::end<const nsStaticAtom* const, 182>(kAttributesSVG), <lambda closure object><lambda(auto:30)>::<lambda(auto:31)>{aURLAttributeSVG})' 1:30.72 /var/tmp/portage/www-client/firefox-91.10.0/work/firefox-91.10.0/dom/base/nsTreeSanitizer.cpp:640:59: error: '((& mozilla::detail::gGkAtoms.mozilla::detail::GkAtoms::mAtoms[1541]) == 0)' is not a constant expression 1:30.72 640 | return aAttributeSVG == aURLAttributeSVG; 1:30.73 | Reproducible: Always
Created attachment 783851 [details] build.log (compressed)
Created attachment 783854 [details] emerge --info
As discussed on IRC (just commenting here so nobody else looks into it just yet in case it is this), it looks like it's caused by -fno-delete-null-pointer-checks.
This is indeed an issue with -fno-delete-null-pointer-checks, the build succeeds without this flag.
I see the upstream bug is fixed.
(In reply to Sam James from comment #3) > As discussed on IRC (just commenting here so nobody else looks into it just > yet in case it is this), it looks like it's caused by > -fno-delete-null-pointer-checks. Good to know, appreciate knowing this as I'm definitely using that. 834:26.61 In file included from Unified_cpp_dom_base10.cpp:92: 834:26.61 /var/tmp/portage/www-client/firefox-127.0/work/firefox-127.0/dom/base/nsTreeSanitizer.cpp:637:20: error: non-constant condition for static assertion 834:26.62 637 | static_assert(AllOf(std::begin(kURLAttributesSVG), std::end(kURLAttributesSVG), 834:26.62 | ~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 834:26.62 638 | [](auto aURLAttributeSVG) { 834:26.62 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~ 834:26.62 639 | return AnyOf(std::begin(kAttributesSVG), 834:26.63 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 834:26.63 640 | std::end(kAttributesSVG), 834:26.63 | ~~~~~~~~~~~~~~~~~~~~~~~~~ 834:26.63 641 | [&](auto aAttributeSVG) { 834:26.63 | ~~~~~~~~~~~~~~~~~~~~~~~~~ 834:26.63 642 | return aAttributeSVG == aURLAttributeSVG; 834:26.64 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 834:26.64 643 | }); 834:26.64 | ~~~ 834:26.64 644 | })); 834:26.64 | ~~ 834:26.64 /var/tmp/portage/www-client/firefox-127.0/work/firefox-127.0/dom/base/nsTreeSanitizer.cpp:637:20: in 'constexpr' expansion of 'mozilla::AllOf<const nsStaticAtom* const*, <lambda(auto:42)> >(std::begin<const nsStaticAtom* const, 2>(kURLAttributesSVG), std::end<const nsStaticAtom* const, 2>(kURLAttributesSVG), (<lambda closure object><lambda(auto:42)>(), <lambda(auto:42)>()))' 834:26.65 /var/tmp/portage/www-client/firefox-127.0/work/firefox_build/dist/include/mozilla/Algorithm.h:24:15: in 'constexpr' expansion of 'aPred.<lambda(auto:42)>(((const nsStaticAtom*)(* aFirst)))' 834:26.65 /var/tmp/portage/www-client/firefox-127.0/work/firefox-127.0/dom/base/nsTreeSanitizer.cpp:639:35: in 'constexpr' expansion of 'mozilla::AnyOf<const nsStaticAtom* const*, <lambda(auto:42)>::<lambda(auto:43)> >(std::begin<const nsStaticAtom* const, 182>(kAttributesSVG), std::end<const nsStaticAtom* const, 182>(kAttributesSVG), <lambda closure object><lambda(auto:42)>::<lambda(auto:43)>{aURLAttributeSVG})' 834:26.65 /var/tmp/portage/www-client/firefox-127.0/work/firefox-127.0/dom/base/nsTreeSanitizer.cpp:642:59: error: '((& mozilla::detail::gGkAtoms.mozilla::detail::GkAtoms::mAtoms[1581]) == 0)' is not a constant expression 834:26.66 642 | return aAttributeSVG == aURLAttributeSVG; 834:26.66 | ~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~ 834:26.66 In file included from /var/tmp/portage/www-client/firefox-127.0/work/firefox_build/dist/include/mozilla/dom/ModuleLoader.h:11, 834:26.66 from /var/tmp/portage/www-client/firefox-127.0/work/firefox_build/dist/include/mozilla/dom/ScriptLoader.h:29, 834:26.66 from /var/tmp/portage/www-client/firefox-127.0/work/firefox_build/dist/include/mozilla/dom/WorkerPrivate.h:12, 834:26.67 from /var/tmp/portage/www-client/firefox-127.0/work/firefox_build/dist/include/mozilla/dom/ProcessIsolation.h:15, 834:26.67 from /var/tmp/portage/www-client/firefox-127.0/work/firefox_build/dist/include/mozilla/dom/CanonicalBrowsingContext.h:13, 834:26.67 from /var/tmp/portage/www-client/firefox-127.0/work/firefox-127.0/dom/base/nsWindowRoot.cpp:29, 834:26.67 from Unified_cpp_dom_base10.cpp:119: