summaryrefslogtreecommitdiffstats
path: root/test/CodeGenCXX/static-data-member.cpp
blob: b3a2af2aafe32c847e43f28380244491484bf3ab (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
// RUN: %clang_cc1 -emit-llvm -o - %s

// CHECK: @_ZN1A1aE = constant i32 10

// PR5564.
struct A {
  static const int a = 10;
};

const int A::a;

struct S { 
  static int i;
};

void f() { 
  int a = S::i;
}
OpenPOWER on IntegriCloud