Created attachment 22994 [details] Demonstration of how __FILE__ is modified Clang's preprocessor appears to prepend "./" to __FILE__ every time it encounters "#include __FILE__" in a source code. This can be observed by how 3 different strings are printed for this code: #ifndef INCLUDE_GUARD #define INCLUDE_GUARD #include <stdio.h> int main(int argc, char **argv) { puts(__FILE__); #include __FILE__ puts(__FILE__); #include __FILE__ puts(__FILE__); return 0; } #endif https://gcc.godbolt.org/z/JTx2Np If a piece of code manages to #include itself a finite but large number of times, "#include __FILE__" will eventually fail because __FILE__ contains a string longer than what's supported by the local file system. The preprocessor should just keep __FILE__ constant. Clang 3.5.1 and earlier and all versions of GCC has the expected behavior, Clang 3.6 and later appears to modify __FILE__.