File tree Expand file tree Collapse file tree 3 files changed +16
-1
lines changed Expand file tree Collapse file tree 3 files changed +16
-1
lines changed Original file line number Diff line number Diff line change @@ -263,6 +263,8 @@ class CompilerInvocation {
263
263
assert (Buf);
264
264
CodeCompletionBuffer = Buf;
265
265
CodeCompletionOffset = Offset;
266
+ // We don't need typo-correction for code-completion.
267
+ LangOpts.DisableTypoCorrection = true ;
266
268
}
267
269
268
270
std::pair<llvm::MemoryBuffer *, unsigned > getCodeCompletionPoint () const {
Original file line number Diff line number Diff line change @@ -396,8 +396,8 @@ func resyncParserB11() {}
396
396
// rdar://21346928
397
397
func optStr( ) -> String ? { return nil }
398
398
let x = ( optStr ( ) ?? " autoclosure " ) . #^TOP_LEVEL_AUTOCLOSURE_1^#
399
- // AUTOCLOSURE_STRING: Decl[InstanceVar]/CurrNominal: utf16[#String.UTF16View#]
400
399
// AUTOCLOSURE_STRING: Decl[InstanceVar]/CurrNominal: characters[#String.CharacterView#]
400
+ // AUTOCLOSURE_STRING: Decl[InstanceVar]/CurrNominal: utf16[#String.UTF16View#]
401
401
// AUTOCLOSURE_STRING: Decl[InstanceVar]/CurrNominal: utf8[#String.UTF8View#]
402
402
403
403
func resyncParserB12( ) { }
Original file line number Diff line number Diff line change
1
+ // RUN: %target-swift-ide-test -code-completion -source-filename %s -code-completion-token=HERE -code-completion-diagnostics 2> %t.err.txt
2
+ // RUN: %FileCheck %s -input-file=%t.err.txt
3
+
4
+ // CHECK: use of unresolved identifier 'foo11'
5
+ // CHECK-NOT: did you mean
6
+
7
+ func foo12( ) -> Int { return 0 }
8
+
9
+ class C {
10
+ var p = foo11 ( )
11
+ }
12
+
13
+ C ( ) . #^HERE^#
You can’t perform that action at this time.
0 commit comments