kuilpd wrote: > The code I'm referring to is the `UniqueDWARFASTTypeMap` class (and the code > surrounding it). We use that to determine whether to DIEs describe the same > type. My idea was something like: a) look up the type that is supposed to > contain the variable we're searching for (using `FindTypes` or something like > that); b) get the DWARF DIE describing that type; c) look at the children of > that DIE for the variable
Thank you, I will look into it. > It might actually be better to fix this problem during indexing, in the > ManualDWARFIndex -- basically, if we're indexing a v4 unit _and_ we run into > a static const(expr?) variable (can we detect that reliably by looking at the > DIE alone?), then we add it to the index, just as if it was a v5 > DW_TAG_variable. This sounds like the best solution indeed. I will try doing this first and see if it's possible at all to detect such a case. However, there might be other cases where global variables are not tagged as `DW_TAG_variable`, but to be honest I don't know any other example other than `static constexpr` anyway. https://github.com/llvm/llvm-project/pull/111859 _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits