25 lines · cpp
1// Tests that we can evaluate functions that Clang2// classifies as having clang::Linkage::UniqueExternal3// linkage. In this case, a function whose argument4// is not legally usable outside this TU.5 6// XFAIL: target-windows7 8// RUN: %build %s -o %t9// RUN: %lldb %t -o run -o "expression func(a)" -o exit | FileCheck %s10 11// CHECK: expression func(a)12// CHECK: (int) $0 = 1513 14namespace {15struct InAnon {};16} // namespace17 18int func(InAnon a) { return 15; }19 20int main() {21 InAnon a;22 __builtin_debugtrap();23 return func(a);24}25