aboutsummaryrefslogtreecommitdiff
path: root/lib/Frontend/PCHReaderStmt.cpp
diff options
context:
space:
mode:
authorJohn McCall <rjmccall@apple.com>2009-12-08 09:08:17 +0000
committerJohn McCall <rjmccall@apple.com>2009-12-08 09:08:17 +0000
commitdbd872f273a8dbf22e089b3def6c09f0a460965d (patch)
treec8cfd035661ae13cd3d2a147a748714c0e8b9de3 /lib/Frontend/PCHReaderStmt.cpp
parent7c9624ba29bc700c3aa6c65c5363174a890c534e (diff)
DeclRefExpr stores a ValueDecl internally.
Template instantiation can re-use DeclRefExprs. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90848 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Frontend/PCHReaderStmt.cpp')
-rw-r--r--lib/Frontend/PCHReaderStmt.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Frontend/PCHReaderStmt.cpp b/lib/Frontend/PCHReaderStmt.cpp
index b2fc644c6d..f28e61e1ec 100644
--- a/lib/Frontend/PCHReaderStmt.cpp
+++ b/lib/Frontend/PCHReaderStmt.cpp
@@ -349,7 +349,7 @@ unsigned PCHStmtReader::VisitPredefinedExpr(PredefinedExpr *E) {
unsigned PCHStmtReader::VisitDeclRefExpr(DeclRefExpr *E) {
VisitExpr(E);
- E->setDecl(cast<NamedDecl>(Reader.GetDecl(Record[Idx++])));
+ E->setDecl(cast<ValueDecl>(Reader.GetDecl(Record[Idx++])));
E->setLocation(SourceLocation::getFromRawEncoding(Record[Idx++]));
// FIXME: read qualifier
// FIXME: read explicit template arguments