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]

Re: PATCH to implement `restrict' in C


law@cygnus.com (Jeffrey A Law) writes:

> I'm not sure we want a -f option to control restrict.  I think we're
> better off with an option that enables isoc9x features, instead of
> controlling each one separately.

I've not yet finished my patch for this but hopefully will sometime
soon.  Until the C variant selection is possible we can live with the
usual __*__ variant of the name.

> I think this would be a serious limitation, in the light of C9X
> compliance. When I read the draft right
> 
> struct foo{
>   struct foo * restrict next;
>   int value;
> };

It's indeed necesary to support restrict as a type qualifier in the
same way as volatile and const are handled.  Says ISO C 9x.


For C++: I thinke it would help a lot.

-- 
---------------.      drepper at gnu.org  ,-.   1325 Chesapeake Terrace
Ulrich Drepper  \    ,-------------------'   \  Sunnyvale, CA 94089 USA
Cygnus Solutions `--' drepper at cygnus.com   `------------------------


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