diff options
author | Dan Albert <danalbert@google.com> | 2016-02-24 13:48:45 -0800 |
---|---|---|
committer | Dan Albert <danalbert@google.com> | 2016-02-24 13:51:18 -0800 |
commit | b9de1157289455b0ca26daff519d4a0ddcd1fa13 (patch) | |
tree | 4c56cc0a34b91f17033a40a455f26652304f7b8d /gcc-4.8.1/gcc/testsuite/gcc.dg/gnu99-const-expr-1.c | |
parent | 098157a754787181cfa10e71325832448ddcea98 (diff) | |
download | toolchain_gcc-b9de1157289455b0ca26daff519d4a0ddcd1fa13.tar.gz toolchain_gcc-b9de1157289455b0ca26daff519d4a0ddcd1fa13.tar.bz2 toolchain_gcc-b9de1157289455b0ca26daff519d4a0ddcd1fa13.zip |
Update 4.8.1 to 4.8.3.
My previous drop was the wrong version. The platform mingw is
currently using 4.8.3, not 4.8.1 (not sure how I got that wrong).
From ftp://ftp.gnu.org/gnu/gcc/gcc-4.8.3/gcc-4.8.3.tar.bz2.
Bug: http://b/26523949
Change-Id: Id85f1bdcbbaf78c7d0b5a69e74c798a08f341c35
Diffstat (limited to 'gcc-4.8.1/gcc/testsuite/gcc.dg/gnu99-const-expr-1.c')
-rw-r--r-- | gcc-4.8.1/gcc/testsuite/gcc.dg/gnu99-const-expr-1.c | 56 |
1 files changed, 0 insertions, 56 deletions
diff --git a/gcc-4.8.1/gcc/testsuite/gcc.dg/gnu99-const-expr-1.c b/gcc-4.8.1/gcc/testsuite/gcc.dg/gnu99-const-expr-1.c deleted file mode 100644 index da7076ff8..000000000 --- a/gcc-4.8.1/gcc/testsuite/gcc.dg/gnu99-const-expr-1.c +++ /dev/null @@ -1,56 +0,0 @@ -/* Test for constant expressions: GNU extensions. */ -/* Origin: Joseph Myers <joseph@codesourcery.com> */ -/* { dg-do compile } */ -/* { dg-options "-std=gnu99 -pedantic-errors" } */ - -int n; - -void -f (void) -{ - int i = 0; - int a[n]; - enum e1 { - /* Integer constant expressions may not contain statement - expressions (not a permitted operand). */ - E1 = (1 ? 0 : ({ 0; })), /* { dg-error "constant expression" } */ - /* { dg-error "ISO C forbids braced-groups" "ISO" { target *-*-* } 16 } */ - /* Real and imaginary parts act like other arithmetic - operators. */ - E2 = __real__ (1 ? 0 : i++), /* { dg-error "constant expression" } */ - E3 = __real__ 0, - E4 = __imag__ (1 ? 0 : i++), /* { dg-error "constant" } */ - E5 = __imag__ 0, - /* __alignof__ always constant. */ - E6 = __alignof__ (int[n]), - E7 = __alignof__ (a), /* { dg-error "__alignof__ \\(expression\\)" } */ - /* __extension__ ignored for constant expression purposes. */ - E8 = __extension__ (1 ? 0 : i++), /* { dg-error "constant expression" } */ - E9 = __extension__ 0, - /* Conditional expressions with omitted arguments act like the - standard type. */ - E10 = (1 ? : i++), /* { dg-error "constant expression" } */ - /* { dg-error "ISO C forbids omitting" "ISO" { target *-*-* } 32 } */ - E11 = (1 ? : 0) /* { dg-error "ISO C forbids omitting" } */ - }; - enum e2 { - /* Complex integer constants may be cast directly to integer - types, but not after further arithmetic on them. */ - F1 = (int) (_Complex int) 2i, /* { dg-error "constant expression" } */ - /* { dg-error "complex" "complex" { target *-*-* } 39 } */ - /* { dg-error "imaginary" "imaginary" { target *-*-* } 39 } */ - F2 = (int) +2i, /* { dg-error "constant expression" } */ - /* { dg-error "imaginary" "ISO" { target *-*-* } 42 } */ - F3 = (int) (1 + 2i), /* { dg-error "constant expression" } */ - /* { dg-error "imaginary" "ISO" { target *-*-* } 44 } */ - F4 = (int) 2i /* { dg-error "imaginary" } */ - }; - static double dr = __real__ (1.0 + 2.0i); - /* { dg-error "imaginary" "ISO" { target *-*-* } 48 } */ - static double di = __imag__ (1.0 + 2.0i); - /* { dg-error "imaginary" "ISO" { target *-*-* } 50 } */ - /* Statement expressions allowed in unevaluated subexpressions in - initializers in gnu99 but not gnu89. */ - static int j = (1 ? 0 : ({ 0; })); - /* { dg-error "braced" "ISO" { target *-*-* } 54 } */ -} |