
A significant number of our tests in C accidentally use functions without prototypes. This patch converts the function signatures to have a prototype for the situations where the test is not specific to K&R C declarations. e.g., void func(); becomes void func(void); This is the tenth batch of tests being updated (there are a significant number of other tests left to be updated).
27 lines
427 B
C
27 lines
427 B
C
// RUN: %clang_cc1 -triple arc-unknown-unknown %s -emit-llvm -o - \
|
|
// RUN: | FileCheck %s
|
|
|
|
// 64-bit fields need only be 32-bit aligned for arc.
|
|
|
|
typedef struct {
|
|
int aa;
|
|
double bb;
|
|
} s1;
|
|
|
|
// CHECK: define{{.*}} i32 @f1
|
|
// CHECK: ret i32 12
|
|
int f1(void) {
|
|
return sizeof(s1);
|
|
}
|
|
|
|
typedef struct {
|
|
int aa;
|
|
long long bb;
|
|
} s2;
|
|
// CHECK: define{{.*}} i32 @f2
|
|
// CHECK: ret i32 12
|
|
int f2(void) {
|
|
return sizeof(s2);
|
|
}
|
|
|