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

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
          Component|c++                         |debug
         Resolution|---                         |INVALID
             Status|UNCONFIRMED                 |RESOLVED

--- Comment #2 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
"f<f(T) [with T = f(T) [with T = f(T) [with T =
int]::<lambda()>]::<lambda()>]::<lambda()> >"


vs

"f<f<f<f<int>(int)::<lambda()> >(f<int>(int)::<lambda()>)::<lambda()>
>(f<f<int>(int)::<lambda()> >(f<int>(int)::<lambda()>)::<lambda()>)::<lambda()>
>"
For the DW_AT_name

Clang just uses "f" or "f<(lambda at bug.cpp:3:12)>" for DW_AT_name. 

from https://wiki.dwarfstd.org/Best_Practices.md :
For template instantiations, the DW_AT_name attribute should contain both the
source language name of the object and the template parameters that distinguish
one instantiation from another. The resulting string should be in the natural
form for the language, and should have a canonical representation (i.e.,
different producers should generate the same representation). For C++, the
string should match that produced by the target platform\’s canonical
demangler; spaces should only be inserted where syntactically required by the
compiler.

So GCC is following the best practices while clang is not.

So invalid.

Reply via email to