Skip to content

Commit bd5bff6

Browse files
committed
Renaming
1 parent 4c36440 commit bd5bff6

File tree

1 file changed

+12
-11
lines changed

1 file changed

+12
-11
lines changed

lib/AST/UnqualifiedLookup.cpp

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -179,8 +179,8 @@ class UnqualifiedLookupFactory {
179179
};
180180

181181
struct PerContextInfo {
182-
DeclContext *dc; // TODO: Eliminate ME
183-
DeclContext *lookupContextForThisDecl;
182+
DeclContext *thisContext; // TODO: Eliminate ME
183+
DeclContext *lookupContextForThisContext;
184184
Optional<PlacesToSearch> placesToSearch;
185185
Optional<bool> isCascadingUse;
186186

@@ -672,23 +672,24 @@ void UnqualifiedLookupFactory::lookupNameInDeclContexts(
672672
void UnqualifiedLookupFactory::finishLookingInContext(
673673
const PerContextInfo &&info) {
674674
breadcrumbs.push_back(info);
675-
auto lookupContextForThisDecl = info.lookupContextForThisDecl;
675+
auto lookupContextForThisContext = info.lookupContextForThisContext;
676676
auto placesToSearch = std::move(info.placesToSearch);
677677
auto isCascadingUse = info.isCascadingUse;
678678

679-
if (!isa<DefaultArgumentInitializer>(info.dc) &&
680-
addGenericParametersHereAndInEnclosingScopes(lookupContextForThisDecl))
679+
if (!isa<DefaultArgumentInitializer>(info.thisContext) &&
680+
addGenericParametersHereAndInEnclosingScopes(lookupContextForThisContext))
681681
return;
682682
if (placesToSearch.hasValue() && !placesToSearch.getValue().empty()) {
683683
auto startIndexOfInnerResults = Results.size();
684-
placesToSearch.getValue().addToResults(Name, isCascadingUse.getValue(),
685-
baseNLOptions,
686-
lookupContextForThisDecl, Results);
684+
placesToSearch.getValue().addToResults(
685+
Name, isCascadingUse.getValue(), baseNLOptions,
686+
lookupContextForThisContext, Results);
687687
if (handleUnavailableInnerResults(startIndexOfInnerResults))
688688
return;
689689
}
690-
auto *const whereToLookNext = lookupContextForThisDecl->getParentForLookup();
691-
assert(whereToLookNext != info.dc && "non-termination");
690+
auto *const whereToLookNext =
691+
lookupContextForThisContext->getParentForLookup();
692+
assert(whereToLookNext != info.thisContext && "non-termination");
692693

693694
lookupNameInDeclContexts(
694695
DCAndUnresolvedIsCascadingUse{whereToLookNext, isCascadingUse});
@@ -1723,7 +1724,7 @@ void UnqualifiedLookupFactory::dumpBreadcrumbs() const {
17231724
void UnqualifiedLookupFactory::PerContextInfo::dump() const {
17241725
auto &e = llvm::errs();
17251726
e << " dc: ";
1726-
lookupContextForThisDecl->dumpContext();
1727+
lookupContextForThisContext->dumpContext();
17271728
if (placesToSearch.hasValue())
17281729
placesToSearch.getValue().dump();
17291730
}

0 commit comments

Comments
 (0)