[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
Thu Jan 4 14:21:50 PST 2024


dwblaikie wrote:

Yes, in the totally reduced reproducer - another debugger might be able to do this name lookup with only a declaration, but I understand that at least Clang's AST expression evaluator wouldn't be able to handle this case. (though perhaps the lldb-eval work will provide some opportunity to catch this case)

But at least in our real-world example I think the definition is available, in another DWO in the same executable. But I don't have a small reproducer for that - small examples "just work" (they do find the type definition, don't crash) - but in the larger one we still see the crash depending on exactly where the expression is evaluated (within a fully statically linked binary - so the definition is available, broadly speaking, no matter the context of evaluation - not sure what makes the difference)

If it's helpful to try to identify the more nuanced case where a crash occurs despite the definition being available /somewhere/, I can try to figure that out but it seems difficult to do so. 

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


More information about the cfe-commits mailing list