Mercurial > hg > CbC > CbC_gcc
comparison gcc/testsuite/g++.old-deja/g++.jason/cond.C @ 131:84e7813d76e9
gcc-8.2
author | mir3636 |
---|---|
date | Thu, 25 Oct 2018 07:37:49 +0900 |
parents | 04ced10e8804 |
children |
comparison
equal
deleted
inserted
replaced
111:04ced10e8804 | 131:84e7813d76e9 |
---|---|
45 struct B { operator int () { return 2; } }; | 45 struct B { operator int () { return 2; } }; |
46 | 46 |
47 if (struct B * foo = new B) | 47 if (struct B * foo = new B) |
48 ; | 48 ; |
49 | 49 |
50 if (int f () = 1) // { dg-warning "extern" "extern" } | 50 if (int f () = 1) // { dg-error "declares a function" } |
51 // { dg-error "is initialized like a variable" "var" { target *-*-* } .-1 } | |
52 ; | 51 ; |
53 | 52 |
54 if (int a[2] = {1, 2}) // { dg-error "extended init" "" { target { ! c++11 } } } | 53 if (int a[2] = {1, 2}) // { dg-error "declares an array" } |
55 ; | 54 ; |
56 | 55 |
57 } | 56 } |