[cfe-commits] r38730 - /cfe/cfe/trunk/Lex/Pragma.cpp
sabre at cs.uiuc.edu
sabre at cs.uiuc.edu
Wed Jul 11 09:24:10 PDT 2007
Author: sabre
Date: Wed Jul 11 11:24:09 2007
New Revision: 38730
URL: http://llvm.org/viewvc/llvm-project?rev=38730&view=rev
Log:
Simplify this by using a higher-level method.
Modified:
cfe/cfe/trunk/Lex/Pragma.cpp
Modified: cfe/cfe/trunk/Lex/Pragma.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/cfe/trunk/Lex/Pragma.cpp?rev=38730&r1=38729&r2=38730&view=diff
==============================================================================
--- cfe/cfe/trunk/Lex/Pragma.cpp (original)
+++ cfe/cfe/trunk/Lex/Pragma.cpp Wed Jul 11 11:24:09 2007
@@ -14,7 +14,6 @@
#include "clang/Lex/Pragma.h"
#include "clang/Lex/Preprocessor.h"
-#include "clang/Lex/ScratchBuffer.h"
#include "clang/Basic/Diagnostic.h"
#include "clang/Basic/FileManager.h"
#include "clang/Basic/SourceManager.h"
@@ -135,8 +134,7 @@
// Plop the string (including the trailing null) into a buffer where we can
// lex it.
- SourceLocation TokLoc = ScratchBuf->getToken(&StrVal[0], StrVal.size(),
- StrLoc);
+ SourceLocation TokLoc = CreateString(&StrVal[0], StrVal.size(), StrLoc);
const char *StrData = SourceMgr.getCharacterData(TokLoc);
unsigned FileID = TokLoc.getFileID();
More information about the cfe-commits
mailing list