[cfe-commits] r136893 - in /cfe/trunk: include/clang/Serialization/ASTReader.h lib/Serialization/ASTReader.cpp
Douglas Gregor
dgregor at apple.com
Thu Aug 4 11:09:14 PDT 2011
Author: dgregor
Date: Thu Aug 4 13:09:14 2011
New Revision: 136893
URL: http://llvm.org/viewvc/llvm-project?rev=136893&view=rev
Log:
Remove the unset, unused return value of
ASTReader::ReadMacroRecord(). No functionality change.
Modified:
cfe/trunk/include/clang/Serialization/ASTReader.h
cfe/trunk/lib/Serialization/ASTReader.cpp
Modified: cfe/trunk/include/clang/Serialization/ASTReader.h
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/Serialization/ASTReader.h?rev=136893&r1=136892&r2=136893&view=diff
==============================================================================
--- cfe/trunk/include/clang/Serialization/ASTReader.h (original)
+++ cfe/trunk/include/clang/Serialization/ASTReader.h Thu Aug 4 13:09:14 2011
@@ -1589,7 +1589,7 @@
Expr *ReadSubExpr();
/// \brief Reads the macro record located at the given offset.
- PreprocessedEntity *ReadMacroRecord(Module &F, uint64_t Offset);
+ void ReadMacroRecord(Module &F, uint64_t Offset);
/// \brief Reads the preprocessed entity located at the current stream
/// position.
Modified: cfe/trunk/lib/Serialization/ASTReader.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Serialization/ASTReader.cpp?rev=136893&r1=136892&r2=136893&view=diff
==============================================================================
--- cfe/trunk/lib/Serialization/ASTReader.cpp (original)
+++ cfe/trunk/lib/Serialization/ASTReader.cpp Thu Aug 4 13:09:14 2011
@@ -1413,7 +1413,7 @@
}
}
-PreprocessedEntity *ASTReader::ReadMacroRecord(Module &F, uint64_t Offset) {
+void ASTReader::ReadMacroRecord(Module &F, uint64_t Offset) {
assert(PP && "Forgot to set Preprocessor ?");
llvm::BitstreamCursor &Stream = F.MacroCursor;
@@ -1430,14 +1430,14 @@
unsigned Code = Stream.ReadCode();
switch (Code) {
case llvm::bitc::END_BLOCK:
- return 0;
+ return;
case llvm::bitc::ENTER_SUBBLOCK:
// No known subblocks, always skip them.
Stream.ReadSubBlockID();
if (Stream.SkipBlock()) {
Error("malformed block record in AST file");
- return 0;
+ return;
}
continue;
@@ -1461,12 +1461,12 @@
// of the definition of the macro we were looking for. We're
// done.
if (Macro)
- return 0;
+ return;
IdentifierInfo *II = getLocalIdentifier(F, Record[0]);
if (II == 0) {
Error("macro must have a name in AST file");
- return 0;
+ return;
}
SourceLocation Loc = ReadSourceLocation(F, Record[1]);
bool isUsed = Record[2];
@@ -1530,7 +1530,7 @@
}
}
- return 0;
+ return;
}
PreprocessedEntity *ASTReader::LoadPreprocessedEntity(Module &F) {
More information about the cfe-commits
mailing list