This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH, testsuite] ignore some "conflicting types for built-in" messages


On 11/05/2018 08:12 AM, Paul Koning wrote:


On Nov 3, 2018, at 10:12 PM, Jeff Law <law@redhat.com> wrote:

On 11/1/18 1:13 PM, Paul Koning wrote:
A number of test cases contain declarations like:
 void *memcpy();
which currently are silently accepted on most platforms but not on all; pdp11 (and possibly some others) generate a "conflicting types for built-in function" warning.

It was suggested to prune those messages because the test cases where these occur are not looking for the message but are testing some other issue, so the message is not relevant.  The attached patch adds dg-prune-output directives to do so.

Ok for trunk?

	paul

ChangeLog:

2018-11-01  Paul Koning  <ni1d@arrl.net>

	* gcc.dg/Walloca-16.c: Ignore conflicting types for built-in
	warnings.
	* gcc.dg/Wrestrict-4.c: Ditto.
	* gcc.dg/Wrestrict-5.c: Ditto.
	* gcc.dg/pr83463.c: Ditto.
	* gcc.dg/torture/pr55890-2.c: Ditto.
	* gcc.dg/torture/pr55890-3.c: Ditto.
	* gcc.dg/torture/pr71816.c: Ditto.
ISTM it'd be better to just fix memcpy to have a correct prototype.

jeff

I can do that, but I'm wondering if some systems have different prototypes than the C standard calls for so I'd end up breaking those.

The tests verify that GCC doesn't crash on calls to built-ins
declared without a prototype.  We don't want to declare them,
that would defeat the purpose of the tests.

Martin


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]