[Lldb-commits] [lldb] [lldb] Add enum lookup to DIL (PR #192065)
Ilia Kuklin via lldb-commits
lldb-commits at lists.llvm.org
Fri Apr 17 06:54:32 PDT 2026
================
@@ -380,6 +380,31 @@ lldb::ValueObjectSP LookupIdentifier(llvm::StringRef name_ref,
return nullptr;
}
+lldb::ValueObjectSP LookupEnumValue(llvm::StringRef name_ref,
+ std::shared_ptr<StackFrame> stack_frame) {
+ if (name_ref.contains("::")) {
----------------
kuilpd wrote:
Yes, the logic is to get the enum name and search through its constants to see if there's one that matches the constant name.
Without the qualified name, we would have to go through all enums and search which one has the right constant name. But in the case when there is multiple enums in different namespaces with the same constant name, there is not good mechanism to see which one is closer to our scope. For this reason we don't search for unqualified types in DIL either, so I don't think it's worth pursuing,
https://github.com/llvm/llvm-project/pull/192065
More information about the lldb-commits
mailing list