| Subject: | inconsistent macro behavior |
|---|---|
| From: | RezaRob <RezaRob@xxxxxxxxx> |
| Date: | Sun, 27 Jul 2008 11:01:52 -0700 (PDT) |
| Newsgroups: | gnu.gcc.help, gnu.gcc.bug |
Hi, this is the test file: $ cat test.c #define x "llll #define y " char * c = x y ; Now, if I do this: $ gcc -Wall -E test.c It works as expected, and produces preprocessed output that is perfectly compilable. But, if I do this: $ gcc -Wall -c test.c -o test.o Then I get this: test.c:3: error: missing terminating " character test.c:3: error: missing terminating " character test.c:3: error: expected expression before ‘;’ token The questions are: a.) What's even going on here? Why the apparent inconsistency? b.) What _should_ be the correct behavior, both in terms of the (extended) GNU C language, and also the standard C language? Thanks so much for your help. Reza. |
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| ||
| Previous by Date: | Re: What have I done wrong?, Pilcrow |
|---|---|
| Next by Date: | Re: How do I get a warning or error when returning values from functions returning void in GCC?, bgutter |
| Previous by Thread: | Test for availability of __sync builtins, Luke D |
| Next by Thread: | Re: Is this code in gcc 4.3.1 valid C or is Sun compiler wrong ??, David Eisner |
| Indexes: | [Date] [Thread] [Top] [All Lists] |