aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.dg/c99-const-expr-10.c
diff options
context:
space:
mode:
authorAndrew Pinski <pinskia@gmail.com>2010-06-08 03:56:40 +0000
committerShujing Zhao <pzhao@gcc.gnu.org>2010-06-08 03:56:40 +0000
commit6a8f4e12f5e44e292123c7424f703f8a7206e3a5 (patch)
treeb977e0467d5267b3458fe2a20c3d142eb7180965 /gcc/testsuite/gcc.dg/c99-const-expr-10.c
parentc8061de73f1ec2db31588f1c20693d570d576a20 (diff)
downloadgcc-6a8f4e12f5e44e292123c7424f703f8a7206e3a5.zip
gcc-6a8f4e12f5e44e292123c7424f703f8a7206e3a5.tar.gz
gcc-6a8f4e12f5e44e292123c7424f703f8a7206e3a5.tar.bz2
re PR c/37724 ("initialization from incompatible pointer type" does not say which field is being initialized)
gcc/ 2010-06-08 Andrew Pinski <pinskia@gmail.com> Shujing Zhao <pearly.zhao@oracle.com> PR c/37724 * c-typeck.c (convert_for_assignment): Call pedwarn_init if the implicit bad conversions is initialization. (error_init): Use gmsgid instead of msgid for argument name and change the call for error. (pedwarn_init): Use gmsgid instead of msgid for argument name and change the call for pedwarn. (warning_init): Use gmsgid instead of msgid for argument name and change the call for warning. gcc/testsuite/ 2010-06-08 Andrew Pinski <pinskia@gmail.com> Shujing Zhao <pearly.zhao@oracle.com> PR c/37724 * gcc.dg/c90-const-expr-10.c: Adjust. * gcc.dg/c99-const-expr-10.c: Adjust. * gcc.dg/init-bad-7.c: New. From-SVN: r160418
Diffstat (limited to 'gcc/testsuite/gcc.dg/c99-const-expr-10.c')
-rw-r--r--gcc/testsuite/gcc.dg/c99-const-expr-10.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/gcc/testsuite/gcc.dg/c99-const-expr-10.c b/gcc/testsuite/gcc.dg/c99-const-expr-10.c
index 8e5a104..2aca610 100644
--- a/gcc/testsuite/gcc.dg/c99-const-expr-10.c
+++ b/gcc/testsuite/gcc.dg/c99-const-expr-10.c
@@ -6,7 +6,7 @@
/* { dg-options "-std=iso9899:1999 -pedantic-errors" } */
void *p = (__SIZE_TYPE__)(void *)0; /* { dg-error "without a cast" } */
-struct s { void *a; } q = { (__SIZE_TYPE__)(void *)0 }; /* { dg-error "without a cast" } */
+struct s { void *a; } q = { (__SIZE_TYPE__)(void *)0 }; /* { dg-error "without a cast|near initialization" } */
void *
f (void)
{