Question

I am compiling a YACC file using Cygwin shell on a PC. I am getting an 'unknown character \15'. The weird thing is that a co-worker on another machine can compile the exact same file using the same shell with no warnings or errors. Is there some kind of flag I need to set in my shell or with the compiler? We are using nmake and a Visual Studio compiler. I will be happy to provide more info if needed.

Thank you very much!

Was it helpful?

Solution

Check your end-of-line settings. You probably have CRLF and YACC expects LF only. CR is ASCII 13 (15 in octal).

OTHER TIPS

When you install cygwin you get asked about what the default EOL (end of line) should be, traditional unix "\n" or traditional dos "\r\n". My guess is that you and your co-worker have cygwin configured differently. You probably want to run your setup.exe again and select dos EOL.

Octal 15 is a carriage return. Did you transfer the file in text mode from your coworker's machine?

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top