Skip to content

Commit 6c900d6

Browse files
[clang] [Sema] Add assertion about expected type classes when building MemberPointerType
1 parent 70c1764 commit 6c900d6

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

clang/lib/Sema/SemaType.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5363,6 +5363,9 @@ static TypeSourceInfo *GetFullTypeForDeclarator(TypeProcessingState &state,
53635363
// non-dependent one (RecordType).
53645364
ClsType = Context.getElaboratedType(ElaboratedTypeKeyword::None,
53655365
NNSPrefix, ClsType);
5366+
} else {
5367+
// The only other type we should get here is TemplateTypeParmType.
5368+
assert(isa<TemplateTypeParmType>(NNSType));
53665369
}
53675370
break;
53685371
}

0 commit comments

Comments
 (0)