Simplify CXXScopeSpec a lot. No more weird SmallVector-like hacks here
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@67800 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Sema/SemaCXXScopeSpec.cpp b/lib/Sema/SemaCXXScopeSpec.cpp
index ca864a2..8fb2811 100644
--- a/lib/Sema/SemaCXXScopeSpec.cpp
+++ b/lib/Sema/SemaCXXScopeSpec.cpp
@@ -25,7 +25,7 @@
return 0;
NestedNameSpecifier *NNS
- = static_cast<NestedNameSpecifier *>(SS.getCurrentScopeRep());
+ = static_cast<NestedNameSpecifier *>(SS.getScopeRep());
if (NNS->isDependent())
return 0;
@@ -57,7 +57,7 @@
return false;
NestedNameSpecifier *NNS
- = static_cast<NestedNameSpecifier *>(SS.getCurrentScopeRep());
+ = static_cast<NestedNameSpecifier *>(SS.getScopeRep());
return NNS->isDependent();
}
@@ -111,7 +111,7 @@
SourceLocation CCLoc,
IdentifierInfo &II) {
NestedNameSpecifier *Prefix
- = static_cast<NestedNameSpecifier *>(SS.getCurrentScopeRep());
+ = static_cast<NestedNameSpecifier *>(SS.getScopeRep());
// If the prefix is already dependent, there is no name lookup to
// perform. Just build the resulting nested-name-specifier.
@@ -173,7 +173,7 @@
SourceRange TypeRange,
SourceLocation CCLoc) {
NestedNameSpecifier *Prefix
- = static_cast<NestedNameSpecifier *>(SS.getCurrentScopeRep());
+ = static_cast<NestedNameSpecifier *>(SS.getScopeRep());
return NestedNameSpecifier::Create(Context, Prefix, /*FIXME:*/false,
QualType::getFromOpaquePtr(Ty).getTypePtr());
}