diff options
Diffstat (limited to 'test/CodeGenCXX/const-global-linkage.cpp')
-rw-r--r-- | test/CodeGenCXX/const-global-linkage.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/test/CodeGenCXX/const-global-linkage.cpp b/test/CodeGenCXX/const-global-linkage.cpp new file mode 100644 index 0000000000..ddf435823b --- /dev/null +++ b/test/CodeGenCXX/const-global-linkage.cpp @@ -0,0 +1,8 @@ +// RUN: clang-cc -emit-llvm -o - %s | FileCheck %s + +const int x = 10; +const int y = 20; +// CHECK-NOT: @x +// CHECK: @y = internal constant i32 20 +const int& b() { return y; } + |