Skip to content

Commit

Permalink
Set decl on DeclRefExpr directly during deserialization rather than
Browse files Browse the repository at this point in the history
relying on a setter that might have additional side-effects. NFC.
  • Loading branch information
zygoloid committed Dec 15, 2020
1 parent 6c365cd commit 76edf98
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion clang/lib/Serialization/ASTReaderStmt.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -614,7 +614,7 @@ void ASTStmtReader::VisitDeclRefExpr(DeclRefExpr *E) {
*E->getTrailingObjects<ASTTemplateKWAndArgsInfo>(),
E->getTrailingObjects<TemplateArgumentLoc>(), NumTemplateArgs);

E->setDecl(readDeclAs<ValueDecl>());
E->D = readDeclAs<ValueDecl>();
E->setLocation(readSourceLocation());
E->DNLoc = Record.readDeclarationNameLoc(E->getDecl()->getDeclName());
}
Expand Down

0 comments on commit 76edf98

Please sign in to comment.