Skip to content
Closed
Show file tree
Hide file tree
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
5 changes: 1 addition & 4 deletions lib/Sema/MiscDiagnostics.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1367,10 +1367,7 @@ void swift::fixItAvailableAttrRename(TypeChecker &TC,
if (parsed.isMember()) {
diag.fixItReplace(call->getFn()->getSourceRange(), parsed.ContextName);

} else {
auto *dotCall = dyn_cast<DotSyntaxCallExpr>(call->getFn());
if (!dotCall)
return;
} else if (auto *dotCall = dyn_cast<DotSyntaxCallExpr>(call->getFn())) {

SourceLoc removeLoc = dotCall->getDotLoc();
if (removeLoc.isInvalid())
Expand Down
2 changes: 1 addition & 1 deletion test/1_stdlib/StringDiagnostics_without_Foundation.swift
Original file line number Diff line number Diff line change
Expand Up @@ -27,5 +27,5 @@ func testStringCollectionTypes(s: String) {
struct NotLosslessStringConvertible {}

func testStringInitT() {
_ = String(NotLosslessStringConvertible()) // expected-error{{'init' has been renamed to 'init(describing:)}}
_ = String(NotLosslessStringConvertible()) // expected-error{{'init' has been renamed to 'init(describing:)}}{{14-14=describing: }}
}