Skip to content

Commit 5df4882

Browse files
committed
[NFC] Improve/correct more module selector tests
1 parent de83fd0 commit 5df4882

File tree

1 file changed

+8
-9
lines changed

1 file changed

+8
-9
lines changed

test/NameLookup/module_selector.swift

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -288,7 +288,7 @@ struct AvailableUser {
288288
}
289289

290290
func builderUser2(@main::MyBuilder fn: () -> Void) {}
291-
// FIXME should succeed: expected-error@-1 {{unknown attribute 'MyBuilder'}}
291+
// FIXME improve: expected-error@-1 {{unknown attribute 'MyBuilder'}}
292292
293293
func builderUser3(@ModuleSelectorTestingKit::MyBuilder fn: () -> Void) {}
294294
// no-error
@@ -337,16 +337,15 @@ func main::decl1(
337337
// expected-error@-1 {{name of function declaration cannot be qualified with module selector}}
338338
main::p1: main::A,
339339
// expected-error@-1 {{argument label cannot be qualified with module selector}}
340-
// FIXME access path: expected-error@-2 {{type 'A' is not imported through module 'main'}}
341-
// FIXME access path: expected-note@-3 {{did you mean module 'ModuleSelectorTestingKit'?}} {{13-17=ModuleSelectorTestingKit}}
342-
main::label p2: main::A,
340+
// expected-error@-2 {{type 'A' is not imported through module 'main'}}
341+
// expected-note@-3 {{did you mean module 'ModuleSelectorTestingKit'?}} {{13-17=ModuleSelectorTestingKit}}
342+
main::label p2: main::inout A,
343343
// expected-error@-1 {{argument label cannot be qualified with module selector}}
344-
// FIXME access path: expected-error@-2 {{type 'A' is not imported through module 'main'}}
345-
// FIXME access path: expected-note@-3 {{did you mean module 'ModuleSelectorTestingKit'?}} {{19-23=ModuleSelectorTestingKit}}
346-
label main::p3: main::A
344+
// FIXME: expected-error@-2 {{expected identifier in dotted type}} should be something like {{type 'inout' is not imported through module 'main'}}
345+
label main::p3: @main::escaping () -> A
347346
// expected-error@-1 {{name of parameter declaration cannot be qualified with module selector}}
348-
// FIXME access path: expected-error@-2 {{type 'A' is not imported through module 'main'}}
349-
// FIXME access path: expected-note@-3 {{did you mean module 'ModuleSelectorTestingKit'?}} {{19-23=ModuleSelectorTestingKit}}
347+
// FIXME: expected-error@-2 {{attribute can only be applied to declarations, not types}} should be something like {{type 'escaping' is not imported through module 'main'}}
348+
// FIXME: expected-error@-3 {{expected parameter type following ':'}}
350349
) {
351350
let main::decl1a = "a"
352351
// expected-error@-1 {{name of constant declaration cannot be qualified with module selector}}

0 commit comments

Comments
 (0)