[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Tinycc-devel] C99 static array indices in function args

From: Michael B. Smith
Subject: Re: [Tinycc-devel] C99 static array indices in function args
Date: Thu, 28 Dec 2017 15:28:36 +0000

Go for it and implement it improperly.

People like you make me tired. There are better places to spend my efforts. Bye 

-----Original Message-----
From: Tinycc-devel [mailto:address@hidden On Behalf Of foobar
Sent: Thursday, December 28, 2017 9:49 AM
To: address@hidden
Subject: Re: [Tinycc-devel] C99 static array indices in function args

On Tue, 26 Dec 2017 23:21:15 +0000
"Michael B. Smith" <address@hidden> wrote:

> > > 'restrict' has several defined (not just implied) contracts. This should 
> > > require at least a warning.
> > No.  Warnings are never required diagnostics (and even if, what 
> > specifically would you want to warn about in this case?).  The only 
> > require diagnostics are from constraint violations.  Most other undefined 
> > behaviours don't need to be diagnosed (of course, if easily doable it's 
> > nice to diagnose them).
> Here we disagree.
> If a compiler accepts a construct, but does not implement the construct
> properly or completely, then the compiler should emit a warning indicating
> that. I learned this from Dr. Wirth in 1981, and I used this in the compilers
> I wrote/co-wrote in the 1980's for a mainframe computer manufacturer. I
> believe it is still accurate today.

And I disagree with you.
I doubt anyone is willing to implement this feature "properly", and not even 
the GCC folks did when they first supported it. Right now it is mainly about 
just swallowing it without a hickup, so people can use TCC to compile their 
valid C99 programs without having to remove stuff just to make it compile.

OTOH implementing basic support for it and getting one step closer to full C99 
compatibility probably does not involve more than 10 lines of code changes and 
should be a no-brainer for anyone familiar with TCC's parser.

Tinycc-devel mailing list

reply via email to

[Prev in Thread] Current Thread [Next in Thread]