28 lines · plain
1# In DWARFv5, C++ static data members are represented2# as DW_TAG_variable. We make sure LLDB's expression3# evaluator doesn't crash when trying to parse such4# a DW_TAG_variable DIE, whose parent DIE is only5# a forward declaration.6 7# UNSUPPORTED: system-darwin8# UNSUPPORTED: system-windows9 10# RUN: %clangxx_host %S/Inputs/dwo-static-data-member.cpp \11# RUN: -g -gdwarf-5 -gsplit-dwarf -flimit-debug-info -o %t12# RUN: %lldb %t -s %s -o exit 2>&1 | FileCheck %s13 14breakpoint set -n main15process launch16 17# CHECK: Process {{.*}} stopped18 19# FIXME: The expression evaluator tries to attach20# the static member's VarDecl to the NoCtor RecordDecl21# before passing the AST to clang; this requires the22# RecordDecl to be a full definition. But the debug-info23# only contains forward declaration for NoCtor. So24# LLDB fails to evaluate the expression.25expression NoCtor::i26# CHECK-LABEL: expression NoCtor::i27# CHECK: use of undeclared identifier 'NoCtor'28