aboutsummaryrefslogtreecommitdiff
path: root/lib/Sema/SemaAccess.cpp
diff options
context:
space:
mode:
authorJohn McCall <rjmccall@apple.com>2010-03-25 18:04:51 +0000
committerJohn McCall <rjmccall@apple.com>2010-03-25 18:04:51 +0000
commit32f2fb53d9d7c28c94d8569fd0fcf06cccee0c3d (patch)
tree5a3ac384bc2e42e82731667b31d8d2b0ed46cb3d /lib/Sema/SemaAccess.cpp
parent7eff7c4153faf45b19b5919ef409ee5f6794eb25 (diff)
Preserve type-source information in friend declarations.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@99525 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/SemaAccess.cpp')
-rw-r--r--lib/Sema/SemaAccess.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/Sema/SemaAccess.cpp b/lib/Sema/SemaAccess.cpp
index 62b13d4e95..196bc11779 100644
--- a/lib/Sema/SemaAccess.cpp
+++ b/lib/Sema/SemaAccess.cpp
@@ -330,8 +330,8 @@ static Sema::AccessResult MatchesFriend(Sema &S,
static Sema::AccessResult MatchesFriend(Sema &S,
const EffectiveContext &EC,
FriendDecl *FriendD) {
- if (Type *T = FriendD->getFriendType())
- return MatchesFriend(S, EC, T->getCanonicalTypeUnqualified());
+ if (TypeSourceInfo *T = FriendD->getFriendType())
+ return MatchesFriend(S, EC, T->getType()->getCanonicalTypeUnqualified());
NamedDecl *Friend
= cast<NamedDecl>(FriendD->getFriendDecl()->getCanonicalDecl());