OSDN Git Service

Merge in xfails from PR14107.
[pf3gnuchains/gcc-fork.git] / gcc / testsuite / g++.old-deja / g++.bugs / 900520_02.C
1 // { dg-do assemble  }
2 // g++ 1.37.1 bug 900520_02
3
4 // keywords: reference types, initialization, parameter passing
5
6 typedef int b_array[3];
7 typedef int u_array[];
8
9 typedef b_array &b_array_ref;
10 typedef u_array &u_array_ref;
11
12 void take_b_array_ref (b_array_ref arg) { } // { dg-error "" } passed to here
13
14 extern u_array u_array_gbl_obj;
15
16 u_array_ref u_array_ref_gbl_obj0 = u_array_gbl_obj;
17
18 b_array_ref b_array_ref_gbl_obj0 = u_array_ref_gbl_obj0; // { dg-error "" } invalid declaration
19
20 void test_passing ()
21 {
22   take_b_array_ref (u_array_ref_gbl_obj0); // { dg-error "" } invalid call
23 }
24
25 b_array u_array_gbl_obj;
26
27 int main () { return 0; }