================ @@ -0,0 +1,23 @@ +# UNSUPPORTED: system-darwin, system-windows + +# In DWARFv5, C++ static data members are represented +# as DW_TAG_variable. We make sure LLDB's expression +# evaluator doesn't crash when trying to parse such +# a DW_TAG_variable DIE, whose parent DIE is only +# a forward declaration. + +# RUN: %clangxx_host %S/Inputs/dwo-static-data-member.cpp \ +# RUN: -g -gdwarf-5 -gsplit-dwarf -o %t +# RUN: %lldb %t -s %s -o exit 2>&1 | FileCheck %s + +breakpoint set -n main +process launch + +# CHECK: Process {{.*}} stopped + +# There is no definition for NoCtor anywhere +# in the debug-info, so LLDB can't evaluate +# this expression. +expression NoCtor::i +# CHECK-LABEL: expression NoCtor::i +# CHECK: use of undeclared identifier 'NoCtor' ---------------- dwblaikie wrote:
(totally side note: Pity about how this fails (a) gdb can evaluate this, so it's a bug/limitation in lldb (though it sounds like lldb-eval maybe can handle this, hopefully, and possibly without the need for a running process either) (b) `NoCtor` isn't undeclared - it's declared but not defined, but even saying that wouldn't be quite accurate/wouldn't explain why it can't be evaluated by the debugger, since the info for the `i` member is present But that's just me rambling/not relevant to this bug/regression/immediate issue) https://github.com/llvm/llvm-project/pull/77155 _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits