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] Fix PR c/12446


"Joseph S. Myers" <jsm@polyomino.org.uk> writes:

| On Fri, 3 Oct 2003, Gabriel Dos Reis wrote:
| 
| > More precisely, before C99, it was undefined behaviour if a program
| > needs a non-lvalue array to decay to a pointer.  Apparently, GCC
| 
| No, you get an rvalue of array type.

That is not what comes from the quote to C90 standard and conclusions
in the discussion on comp.std.c.  Note that the issue is "decaying a
non-value array to pointer", not its mere existence. 

|  You can pass it to sizeof (with defined results), 

Yes, but that does not need the array to decay to a pointer.  

-- Gaby


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