Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 6 additions & 4 deletions tools/SourceKit/lib/SwiftLang/SwiftEditor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1022,8 +1022,7 @@ void SwiftDocumentSemanticInfo::processLatestSnapshotAsync(
EditableTextBufferRef EditableBuffer) {

SwiftInvocationRef Invok = InvokRef;
if (!Invok)
return;
if (Invok){

RefPtr<SwiftDocumentSemanticInfo> SemaInfoRef = this;
auto Consumer = std::make_shared<AnnotAndDiagASTConsumer>(EditableBuffer,
Expand All @@ -1035,6 +1034,7 @@ void SwiftDocumentSemanticInfo::processLatestSnapshotAsync(
const void *OncePerASTToken = SemaInfoRef.get();
if (auto ASTMgr = this->ASTMgr.lock()) {
ASTMgr->processASTAsync(Invok, std::move(Consumer), OncePerASTToken);
}
}
}

Expand Down Expand Up @@ -1522,12 +1522,14 @@ class PlaceholderExpansionScanner {
// Unresolved member can have argument too.
Arg = UME->getArgument();
}
if (!Arg)
return false;
if (Arg){

if (EnclosingCallAndArg.first)
OuterExpr = EnclosingCallAndArg.first;
EnclosingCallAndArg = {E, Arg};
return true;
}
return false;
}

bool walkToExprPre(Expr *E) override {
Expand Down