https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92927

--- Comment #1 from Jonathan Wakely <redi at gcc dot gnu.org> ---
(In reply to Hongyu Wang from comment #0)
> It seems to happen after r277588.

Thanks for tracking down the revision that caused it.

The problem is that the functions are 'constexpr' for C++14 mode (and therefore
they are implicitly inline functions). It's undefined for an inline function to
not be declared inline in all translation units.

It seems that one TU is expecting the function to be defined elsewhere, but the
other TUs think it's inline so don't bother emitting a definition.

(More generally, this suggests a broader compatibility problem when adding
'constexpr' dependent on the -std mode.)

Reply via email to