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]

Fix up vla, vm and [*] semantics for C


This patch fixes up vla, vm and [*] semantics for C.

Review points:

Ok to change typeof(vm) evaluation semantics for gnu89?

Ok to change sizeof (vla) evaluation semantics for gnu89?

Ok to narrow vla usage in structs and unions in gnu89?

Ok to narrow vm with extern in gnu89?

Ok to narrow gnu99 to be more like c99 wrt vla/vm/[*]?

I think based upon the testing results, gnu89 and gnu99 need to leave vlas in structures and unions alone, agree? Joseph, want to propose this for the next C standard?

Ok for 4.3?

Ok for 4.2?

For some additional testing, I'll be running all of MacOS through this as well as some industry standard testsuites very shortly. I don't expect any issues, but if I find any, I'll send out a round 2.

The testsuite needs cleanups based upon the above points. affected tests include:

gcc.c-torture/compile/20010605-1.c:7: error: not an ordinary identifier, structure and unions are not ordinary
gcc.c-torture/compile/20020210-1.c:2: error: not an ordinary identifier, structure and unions are not ordinary
gcc.c-torture/compile/20030224-1.c:5: error: not an ordinary identifier, structure and unions are not ordinary
gcc.c-torture/compile/20050801-2.c:4: error: not an ordinary identifier, structure and unions are not ordinary
gcc.c-torture/compile/920428-4.c:1: error: not an ordinary identifier, structure and unions are not ordinary
gcc.c-torture/compile/920501-16.c:1: error: not an ordinary identifier, structure and unions are not ordinary
gcc.c-torture/compile/nested-1.c:10: error: not an ordinary identifier, structure and unions are not ordinary
gcc.c-torture/execute/20020412-1.c:24: error: not an ordinary identifier, structure and unions are not ordinary
gcc.c-torture/execute/20040308-1.c:6: error: not an ordinary identifier, structure and unions are not ordinary
gcc.c-torture/execute/20040423-1.c:6: error: not an ordinary identifier, structure and unions are not ordinary
gcc.c-torture/execute/20041218-2.c:5: error: not an ordinary identifier, structure and unions are not ordinary


And last, thanks to Joseph for all the pointers and help.


Attachment: vla-1c.diffs.txt
Description: Text document


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