Revert "[llvm] Improve llvm.objectsize computation by computing GEP, alloca and mallo...
[llvm-project.git] / clang / test / CodeGen / decl-in-prototype.c
blob7b5941b633731f89ba6830180ba4136ca8e582ea
1 // RUN: %clang_cc1 -triple i386-linux -debug-info-kind=limited -emit-llvm -o - %s | FileCheck %s
3 const int AA = 5;
5 // CHECK-LABEL: define{{.*}} i32 @f1
6 int f1(enum {AA,BB} E) {
7 // CHECK: ret i32 1
8 return BB;
11 // CHECK-LABEL: define{{.*}} i32 @f2
12 int f2(enum {AA=7,BB} E) {
13 // CHECK: ret i32 7
14 return AA;
17 // Check nested function declarators work.
18 int f(void (*g)(void), enum {AA,BB} h) {
19 // CHECK: ret i32 0
20 return AA;
23 // This used to crash with debug info enabled.
24 int pr31366(struct { enum { a = 1 } b; } c) {
25 return a;