Joerg Schilling wrote:
al...@x11x:/tmp [8:12am - 9] cat > foo.c
#include <stdio.h>

int main(int argc, char **argv) {
        printf("Goodbye cruel world\n");
}
al...@x11x:/tmp [8:13am - 10] perl -i -p -e 's/\n/\r\n/' foo.c
al...@x11x:/tmp [8:13am - 11] cc foo.c
"foo.c", line 1: warning: invalid white space character in directive

Interesting. It seems that I used CC ;-), so this is a non-orthogonal
behavior in Sun Studio

You can also avoid the error using cc -Xs. Perhaps ANSI C explicitly disallows the carriage return character as whitespace.

It would be nice to be able to toggle this one behavior while still compiling with -Xa. Anyone know of a not-so-obvious Sun Studio option to do that?

        Scott

--
Scott Rotondo
Principal Engineer, Solaris Security Technologies
President, Trusted Computing Group
Phone/FAX: +1 408 850 3655 (Internal x68278)
_______________________________________________
opensolaris-discuss mailing list
[email protected]

Reply via email to