[cfe-commits] r119996 - /cfe/trunk/lib/Lex/PTHLexer.cpp
Chris Lattner
sabre at nondot.org
Mon Nov 22 20:40:27 PST 2010
Author: lattner
Date: Mon Nov 22 22:40:26 2010
New Revision: 119996
URL: http://llvm.org/viewvc/llvm-project?rev=119996&view=rev
Log:
tidy up
Modified:
cfe/trunk/lib/Lex/PTHLexer.cpp
Modified: cfe/trunk/lib/Lex/PTHLexer.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Lex/PTHLexer.cpp?rev=119996&r1=119995&r2=119996&view=diff
==============================================================================
--- cfe/trunk/lib/Lex/PTHLexer.cpp (original)
+++ cfe/trunk/lib/Lex/PTHLexer.cpp Mon Nov 22 22:40:26 2010
@@ -434,7 +434,7 @@
Diags.Report(Diags.getCustomDiagID(Diagnostic::Error, Msg));
}
-PTHManager* PTHManager::Create(const std::string& file, FileManager &FileMgr,
+PTHManager *PTHManager::Create(const std::string &file, FileManager &FileMgr,
const FileSystemOptions &FSOpts,
Diagnostic &Diags) {
// Memory map the PTH file.
@@ -448,11 +448,11 @@
// Get the buffer ranges and check if there are at least three 32-bit
// words at the end of the file.
- const unsigned char* BufBeg = (unsigned char*)File->getBufferStart();
- const unsigned char* BufEnd = (unsigned char*)File->getBufferEnd();
+ const unsigned char *BufBeg = (unsigned char*)File->getBufferStart();
+ const unsigned char *BufEnd = (unsigned char*)File->getBufferEnd();
// Check the prologue of the file.
- if ((BufEnd - BufBeg) < (signed) (sizeof("cfe-pth") + 3 + 4) ||
+ if ((BufEnd - BufBeg) < (signed)(sizeof("cfe-pth") + 3 + 4) ||
memcmp(BufBeg, "cfe-pth", sizeof("cfe-pth") - 1) != 0) {
Diags.Report(diag::err_invalid_pth_file) << file;
return 0;
More information about the cfe-commits
mailing list