Debian Codegraph @

gcc/testsuite/g++.old-deja/g++.law/init8.C

raw
1 // { dg-do assemble }
2 // GROUPS passed initialization
3 // init file
4 // From: [email protected] (Nikolay Yatsenko)
5 // Date: Wed, 27 Jan 1993 16:39:13 -0500
6 // Subject: g++ bug
7 // Message-ID: <[email protected]>
8
9
10 const int ic = 1;
11 void f(int& arg) // { dg-message "argument 1" }
12 {
13 if (arg) ;
14 }
15 const int& icr = ic;
16
17 int main(void)
18 {
19 f(icr); // { dg-error "const" }
20
21 return 0;
22 }