1 // RUN: %clang_cc1 %s -emit-llvm -o - | FileCheck %s
2 
3 int c[1][3*2];
4 // CHECK: @{{.+}} = {{.*}} global [1 x [6 x {{i[0-9]+}}]] zeroinitializer
5 
6 // CHECK-LABEL: @f
f(int * const m,int (** v)[* m * 2])7 int f(int * const m, int (**v)[*m * 2])
8 {
9     return &(c[0][*m]) == &((*v)[0][*m]);
10     // CHECK: icmp
11     // CHECK: ret i{{[0-9]+}}
12 }
13 
14 // CHECK-LABEL: @test
test(int n,int (* (* fn)(void))[n])15 int test(int n, int (*(*fn)(void))[n]) {
16   return (*fn())[0];
17 }
18 
19 // CHECK-LABEL: @main
main()20 int main()
21 {
22     int m = 3;
23     int (*d)[3*2] = c;
24     int (*fn[m])(void);
25     return f(&m, &d) + test(m, &fn);
26 
27     // CHECK: call {{.+}} @f(
28     // CHECK: ret i{{[0-9]+}}
29 }
30 
31