aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.dg/assign-warn-2.c
diff options
context:
space:
mode:
authorManuel López-Ibáñez <manu@gcc.gnu.org>2008-10-22 16:33:17 +0000
committerManuel López-Ibáñez <manu@gcc.gnu.org>2008-10-22 16:33:17 +0000
commita7da8b427fa7de6a459a0a3b33eca9de953aea62 (patch)
tree02faddfaf2899520e26249176f8c487a14c6b89b /gcc/testsuite/gcc.dg/assign-warn-2.c
parent92010a793b9bc51b3312d9e07f3e83dc86ed1ddc (diff)
downloadgcc-a7da8b427fa7de6a459a0a3b33eca9de953aea62.zip
gcc-a7da8b427fa7de6a459a0a3b33eca9de953aea62.tar.gz
gcc-a7da8b427fa7de6a459a0a3b33eca9de953aea62.tar.bz2
re PR c/30949 ("incompatible pointer type" warning does not point to declaration)
2008-10-22 Manuel López-Ibáñez <manu@gcc.gnu.org> PR c/30949 * c-typeck.c (convert_for_assignment): Do not give declaration's location for builtins. Spell out which type was expected and which was given. testsuite/ * gcc.target/i386/sse-vect-types.c: Update. * gcc.dg/simd-5.c: Update. * gcc.dg/assign-warn-2.c: Update. * gcc.dg/simd-2.c: Update. * gcc.dg/simd-6.c: Update. * gcc.dg/assign-warn-1.c: Update. * gcc.dg/dfp/composite-type.c: Update. * gcc.dg/simd-1.c: Update. * gcc.dg/pr36997.c: Update. From-SVN: r141298
Diffstat (limited to 'gcc/testsuite/gcc.dg/assign-warn-2.c')
-rw-r--r--gcc/testsuite/gcc.dg/assign-warn-2.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/gcc/testsuite/gcc.dg/assign-warn-2.c b/gcc/testsuite/gcc.dg/assign-warn-2.c
index 4656961..f3d861d 100644
--- a/gcc/testsuite/gcc.dg/assign-warn-2.c
+++ b/gcc/testsuite/gcc.dg/assign-warn-2.c
@@ -113,13 +113,13 @@ struct s { int a; };
TESTARG(stria, struct s, int); /* { dg-error "incompatible type for argument 1 of 'striaF'" } */
TESTARP(strib, struct s, int); /* { dg-error "incompatible type for argument 1 of 'stribFp.x'" } */
-TESTASS(stric, struct s, int); /* { dg-error "incompatible types in assignment" } */
+TESTASS(stric, struct s, int); /* { dg-error "incompatible types when assigning to type 'struct s' from type 'int'" } */
TESTINI(strid, struct s, int); /* { dg-error "invalid initializer" } */
-TESTRET(strie, struct s, int); /* { dg-error "incompatible types in return" } */
+TESTRET(strie, struct s, int); /* { dg-error "incompatible types when returning type 'int' but 'struct s' was expected" } */
TESTARG(istra, int, struct s); /* { dg-error "incompatible type for argument 1 of 'istraF'" } */
TESTARP(istrb, int, struct s); /* { dg-error "incompatible type for argument 1 of 'istrbFp.x'" } */
-TESTASS(istrc, int, struct s); /* { dg-error "incompatible types in assignment" } */
-TESTINI(istrd, int, struct s); /* { dg-error "incompatible types in initialization" } */
-TESTRET(istre, int, struct s); /* { dg-error "incompatible types in return" } */
+TESTASS(istrc, int, struct s); /* { dg-error "incompatible types when assigning to type 'int' from type 'struct s'" } */
+TESTINI(istrd, int, struct s); /* { dg-error "incompatible types when initializing type 'int' using type 'struct s'" } */
+TESTRET(istre, int, struct s); /* { dg-error "incompatible types when returning type 'struct s' but 'int' was expected" } */
/* { dg-message "note: expected '\[^'\n\]*' but argument is of type '\[^'\n\]*'" "note: expected" { target *-*-* } 0 } */