Some compilers don't require backslashes to be escaped in preprocessor directives. VC++ 7.1 for example allows that include and will succesfully find the file.
I'm not sure about the standard-ness of it, or how effective it is with other escape sequences, I just wanted to point out that when it comes to preprocessor directives the rules are a little different.
In this case using double backslashes does work as well, but I don't know if that's because they're parsed as a single backslash or because a double backslash in a path has the same effect as a single one.
And how many of your file-names contain newline, bel, backspace or some other "escape" character? In fact, I'm pretty sure all of those are not allowed (in Windows, Linux/Unix allows all sort of "weird" filenames, including those containing just about ANY printable or non-printable characters).
It makes sense that the rules are actually different. The C preprocessor is responsible for replacing the #include "blah.h" wiht the content of blah.h - the compiler is responsible for replacing backslash-quoted characters in strings with the relevant binary. They have no need to follow same or similar rules.
--
Mats
Compilers can produce warnings - make the compiler programmers happy: Use them!
Please don't PM me for help - and no, I don't do help over instant messengers.
But when you #define somename "some string", the C preprocessor will just replace every occurance of somename with "some string" - so the compiler proper doesn't even know it was a #define, but the preprocessor doesn't do anything with the string itself.
--
Mats
Compilers can produce warnings - make the compiler programmers happy: Use them!
Please don't PM me for help - and no, I don't do help over instant messengers.