@@ -1669,7 +1669,7 @@ namespace {
1669
1669
case ScopeLookupResult::finished:
1670
1670
return std::make_pair (ScopeLookupResult::finished, results.nextDC );
1671
1671
}
1672
- if (checkGenericParameters (DC))
1672
+ if (addGenericParametersHereAndInEnclosingScopes (DC))
1673
1673
return std::make_pair (ScopeLookupResult::finished, DC);
1674
1674
1675
1675
// UP TO HERE
@@ -1729,7 +1729,7 @@ namespace {
1729
1729
// / Check the generic parameters of our context.
1730
1730
// / Return true if done with lookup
1731
1731
// / TODO: Factor with addGenericParmeters below
1732
- bool checkGenericParameters (DeclContext *DC) {
1732
+ bool addGenericParametersHereAndInEnclosingScopes (DeclContext *DC) {
1733
1733
for (GenericParamList *dcGenericParams = getGenericParams (DC);
1734
1734
dcGenericParams;
1735
1735
dcGenericParams = dcGenericParams->getOuterParameters ()) {
@@ -1743,7 +1743,7 @@ namespace {
1743
1743
}
1744
1744
1745
1745
// / Consume generic parameters
1746
- void addGenericParameters (AbstractFunctionDecl *AFD) {
1746
+ void addGenericParametersForFunction (AbstractFunctionDecl *AFD) {
1747
1747
// If we're inside a function context, we've already moved to
1748
1748
// the parent DC, so we have to check the function's generic
1749
1749
// parameters first.
@@ -1898,7 +1898,7 @@ namespace {
1898
1898
populateLookupDeclsFromContext (AFD->getDeclContext (), lookupDecls);
1899
1899
DeclContext *const MetaBaseDC = AFD->getDeclContext ();
1900
1900
1901
- addGenericParameters (AFD);
1901
+ addGenericParametersForFunction (AFD);
1902
1902
return PerScopeLookupState{
1903
1903
isFinishedWithLookupNowThatIsAboutToLookForOuterResults ()
1904
1904
? ScopeLookupResult::finished
@@ -1919,7 +1919,7 @@ namespace {
1919
1919
};
1920
1920
}
1921
1921
// Look in the generic parameters after checking our local declaration.
1922
- addGenericParameters (AFD);
1922
+ addGenericParametersForFunction (AFD);
1923
1923
return PerScopeLookupState{
1924
1924
isFinishedWithLookupNowThatIsAboutToLookForOuterResults ()
1925
1925
? ScopeLookupResult::finished
0 commit comments