Remove Lexer::BufferStart, an unneeded instance var.

llvm-svn: 38615
This commit is contained in:
Chris Lattner 2006-07-02 22:30:01 +00:00
parent 8bbfe46475
commit 1840e491dc
3 changed files with 1 additions and 3 deletions

View File

@ -40,7 +40,6 @@ static void InitCharacterInfo();
Lexer::Lexer(const SourceBuffer *File, unsigned fileid, Preprocessor &pp,
const char *BufStart, const char *BufEnd)
: BufferPtr(BufStart ? BufStart : File->getBufferStart()),
BufferStart(BufferPtr),
BufferEnd(BufEnd ? BufEnd : File->getBufferEnd()),
InputFile(File), CurFileID(fileid), PP(pp), Features(PP.getLangOptions()) {
Is_PragmaLexer = false;

View File

@ -420,7 +420,7 @@ void Preprocessor::EnterSourceFileWithLexer(Lexer *TheLexer,
SourceMgr.getFileEntryForFileID(CurLexer->getCurFileID()))
FileType = getFileInfo(FE).DirInfo;
FileChangeHandler(CurLexer->getSourceLocation(CurLexer->BufferStart),
FileChangeHandler(SourceLocation(CurLexer->getCurFileID(), 0),
EnterFile, FileType);
}
}

View File

@ -52,7 +52,6 @@ struct LangOptions {
/// on the specified Preprocessor object to handle preprocessor directives, etc.
class Lexer {
const char *BufferPtr; // Current pointer into the buffer.
const char * const BufferStart;// Start of the buffer.
const char * const BufferEnd; // End of the buffer.
const SourceBuffer *InputFile; // The file we are reading from.
unsigned CurFileID; // FileID for the current input file.