[clang] [clang][DebugInfo] DWARFv5: static data members declarations are DW_TAG_variable (PR #72235)

David Blaikie via cfe-commits cfe-commits at lists.llvm.org
Wed Jan 3 15:38:51 PST 2024


dwblaikie wrote:

Perhaps not surprisingly from the backtrace, the DIE that's tripping things up is the DW_TAG_variable here:
```
0x00003819:   DW_TAG_class_type
                DW_AT_name      ("ScopedLockService")
                DW_AT_declaration       (true)

0x0000381b:     DW_TAG_variable
                  DW_AT_name    ("close_callback")
                  DW_AT_type    (0x00003825 "Callback1<LockService *> *")
                  DW_AT_decl_file       (0x04)
                  DW_AT_decl_line       (531)
                  DW_AT_external        (true)
                  DW_AT_declaration     (true)
```
(so a case where ctor homing/`-fno-standalone-debug` has kept the type definition elsewhere, but the DW_TAG_variable is emitted here)

Might help me reproduce this in a standalone example..

https://github.com/llvm/llvm-project/pull/72235


More information about the cfe-commits mailing list