Commit 2ac2f164 by Joseph Myers Committed by Joseph Myers

c-typeck.c (enum impl_conv): New.

	* c-typeck.c (enum impl_conv): New.
	(convert_for_assignment): Use it.  Take tree for function called
	instead of its name.  Handle ObjC selectors for diagnostics at
	start of function.  Select diagnostic text within the function
	using full sentences for diagnsotics.  Use %qE to name functions
	in diagnostics.
	(convert_arguments, build_modify_expr,
	c_convert_parm_for_inlining, digest_init, c_finish_return): Update
	callers to convert_for_assignment.
	(warn_for_assignment): Remove.

testsuite:
	* gcc.dg/assign-warn-1.c, gcc.dg/assign-warn-2.c: New tests.
	* gcc.dg/warn-1.c, gcc.dg/noncompile/20020213-1.c,
	objc.dg/method-9.m: Update expected diagnostics.

From-SVN: r88741
parent 710acc57
2004-10-08 Joseph S. Myers <jsm@polyomino.org.uk>
* c-typeck.c (enum impl_conv): New.
(convert_for_assignment): Use it. Take tree for function called
instead of its name. Handle ObjC selectors for diagnostics at
start of function. Select diagnostic text within the function
using full sentences for diagnsotics. Use %qE to name functions
in diagnostics.
(convert_arguments, build_modify_expr,
c_convert_parm_for_inlining, digest_init, c_finish_return): Update
callers to convert_for_assignment.
(warn_for_assignment): Remove.
2004-10-08 Nick Clifton <nickc@redhat.com>
* config/sh/symbian.c (symbian_possibly_export_base_class):
......
2004-10-08 Joseph S. Myers <jsm@polyomino.org.uk>
* gcc.dg/assign-warn-1.c, gcc.dg/assign-warn-2.c: New tests.
* gcc.dg/warn-1.c, gcc.dg/noncompile/20020213-1.c,
objc.dg/method-9.m: Update expected diagnostics.
2004-10-07 Geoffrey Keating <geoffk@apple.com>
* gcc.dg/ppc-fsel-3.c: New file.
......
......@@ -24,8 +24,8 @@ int main ()
return 0;
}
/* { dg-warning "passing arg 2 of" "2nd incompatible" { target *-*-* } 15 } */
/* { dg-warning "passing arg 1 of" "1st incompatible" { target *-*-* } 16 } */
/* { dg-warning "passing arg 2 of" "2nd incompatible" { target *-*-* } 16 } */
/* { dg-warning "passing arg 1 of" "1st incompatible" { target *-*-* } 18 } */
/* { dg-warning "passing arg 1 of" "1st incompatible" { target *-*-* } 20 } */
/* { dg-warning "passing argument 2 of" "2nd incompatible" { target *-*-* } 15 } */
/* { dg-warning "passing argument 1 of" "1st incompatible" { target *-*-* } 16 } */
/* { dg-warning "passing argument 2 of" "2nd incompatible" { target *-*-* } 16 } */
/* { dg-warning "passing argument 1 of" "1st incompatible" { target *-*-* } 18 } */
/* { dg-warning "passing argument 1 of" "1st incompatible" { target *-*-* } 20 } */
......@@ -12,5 +12,5 @@ void bar (void)
{
void *vp;
foo (vp); /* { dg-warning "passing arg 1 of" } */
foo (vp); /* { dg-warning "passing argument 1 of" } */
}
......@@ -37,7 +37,7 @@
/* { dg-warning "also found .\\-\\(id\\)initWithData:\\(int\\)data." "" { target *-*-* } 13 } */
/* The following warning is a consequence of picking the "wrong" method signature. */
/* { dg-warning "passing arg 1 of .initWithData:. from incompatible pointer type" "" { target *-*-* } 33 } */
/* { dg-warning "passing argument 1 of .initWithData:. from incompatible pointer type" "" { target *-*-* } 33 } */
return result;
}
@end
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment