[cfe-commits] r38997 - /cfe/cfe/trunk/Lex/Preprocessor.cpp
sabre at cs.uiuc.edu
sabre at cs.uiuc.edu
Wed Jul 11 09:26:40 PDT 2007
Author: sabre
Date: Wed Jul 11 11:26:39 2007
New Revision: 38997
URL: http://llvm.org/viewvc/llvm-project?rev=38997&view=rev
Log:
ignore '#line' and '# 123' for now.
Modified:
cfe/cfe/trunk/Lex/Preprocessor.cpp
Modified: cfe/cfe/trunk/Lex/Preprocessor.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/cfe/trunk/Lex/Preprocessor.cpp?rev=38997&r1=38996&r2=38997&view=diff
==============================================================================
--- cfe/cfe/trunk/Lex/Preprocessor.cpp (original)
+++ cfe/cfe/trunk/Lex/Preprocessor.cpp Wed Jul 11 11:26:39 2007
@@ -1409,11 +1409,10 @@
case tok::eom:
return; // null directive.
-#if 0
case tok::numeric_constant:
// FIXME: implement # 7 line numbers!
- break;
-#endif
+ DiscardUntilEndOfDirective();
+ return;
case tok::kw_else:
return HandleElseDirective(Result);
case tok::kw_if:
@@ -1424,8 +1423,11 @@
bool isExtension = false;
switch (Result.getIdentifierInfo()->getNameLength()) {
case 4:
- if (Directive[0] == 'l' && !strcmp(Directive, "line"))
- ; // FIXME: implement #line
+ if (Directive[0] == 'l' && !strcmp(Directive, "line")) {
+ // FIXME: implement #line
+ DiscardUntilEndOfDirective();
+ return;
+ }
if (Directive[0] == 'e' && !strcmp(Directive, "elif"))
return HandleElifDirective(Result);
if (Directive[0] == 's' && !strcmp(Directive, "sccs"))
More information about the cfe-commits
mailing list