Eliminate "rewritten decls" from the AST writer. NFC
llvm-svn: 251877
This commit is contained in:
@@ -2093,16 +2093,12 @@ void ASTWriter::WriteDecl(ASTContext &Context, Decl *D) {
|
||||
|
||||
// Determine the ID for this declaration.
|
||||
serialization::DeclID ID;
|
||||
if (D->isFromASTFile()) {
|
||||
assert(isRewritten(D) && "should not be emitting imported decl");
|
||||
ID = getDeclID(D);
|
||||
} else {
|
||||
serialization::DeclID &IDR = DeclIDs[D];
|
||||
if (IDR == 0)
|
||||
IDR = NextDeclID++;
|
||||
assert(!D->isFromASTFile() && "should not be emitting imported decl");
|
||||
serialization::DeclID &IDR = DeclIDs[D];
|
||||
if (IDR == 0)
|
||||
IDR = NextDeclID++;
|
||||
|
||||
ID = IDR;
|
||||
}
|
||||
ID = IDR;
|
||||
|
||||
bool isReplacingADecl = ID < FirstDeclID;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user