blob: 4edb2b060f1a11b2d07147a55e85169fb1d80edf [file] [log] [blame]
Filipe Cabecinhas090a2372014-10-18 23:47:59 +00001// RUN: %clangxx %target_itanium_abi_host_triple -O0 -g %s -o %t -c
2// RUN: %clangxx %target_itanium_abi_host_triple %t -o %t.out
Adrian Prantl8b466d52014-03-08 01:21:37 +00003// RUN: %test_debuginfo %s %t.out
4
5// FIXME: LLDB finds the wrong symbol for "C". rdar://problem/14933867
6// XFAIL: darwin
7
8// DEBUGGER: delete breakpoints
9// DEBUGGER: break static-member.cpp:33
10// DEBUGGER: r
11// DEBUGGER: ptype C
12// CHECK: {{struct|class}} C {
13// CHECK: static const int a;
14// CHECK-NEXT: static int b;
15// CHECK-NEXT: static int c;
16// CHECK-NEXT: int d;
17// CHECK-NEXT: }
18// DEBUGGER: p C::a
19// CHECK: ${{[0-9]}} = 4
20// DEBUGGER: p C::c
21// CHECK: ${{[0-9]}} = 15
22
23// PR14471, PR14734
24
25class C {
26public:
27 const static int a = 4;
28 static int b;
29 static int c;
30 int d;
31};
32
33int C::c = 15;
34const int C::a;
35
36int main() {
37 C instance_C;
38 return C::a;
39}