From mboxrd@z Thu Jan 1 00:00:00 1970 From: Andreas Schwab To: gcc-gnats@gcc.gnu.org Subject: preprocessor/3260: #include __FILE__ broken Date: Tue, 19 Jun 2001 07:16:00 -0000 Message-id: <200106191414.f5JEERe08361@D65.suse.de> X-SW-Source: 2001-06/msg00784.html List-Id: >Number: 3260 >Category: preprocessor >Synopsis: #include __FILE__ broken >Confidential: no >Severity: critical >Priority: medium >Responsible: unassigned >State: open >Class: rejects-legal >Submitter-Id: net >Arrival-Date: Tue Jun 19 07:16:01 PDT 2001 >Closed-Date: >Last-Modified: >Originator: >Release: 3.0 20010611 (prerelease) >Organization: >Environment: System: Linux D65 2.4.4 #1 SMP Wed Jun 13 21:43:48 GMT 2001 ia64 unknown Architecture: ia64 host: ia64-suse-linux-gnu build: ia64-suse-linux-gnu target: ia64-suse-linux-gnu configured with: ../configure --enable-threads=posix --enable-long-long --prefix=/usr --with-local-prefix=/usr/local --infodir=/usr/share/info --mandir=/usr/share/man --enable-languages=c,c++,f77,objc,java --with-gxx-include-dir=/usr/include/g++ --enable-nls --with-slibdir=/lib --enable-shared ia64-suse-linux >Description: #include __FILE__ does not work. >How-To-Repeat: $ cat file.c #define PASS 1 #if PASS == 1 #undef PASS #define PASS 2 #include __FILE__ #undef PASS #define PASS 3 #include __FILE__ #endif PASS $ gcc -E file.c file.c:5:18: file.c__: No such file or directory file.c:8:18: file.c__: Success # 10 "file.c" 3 >Fix: >Release-Note: >Audit-Trail: >Unformatted: