mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
These are tests that fail in the next commit without this flag. This does not add -verify-ignore-unrelated to all tests with -verify, only the ones that would fail without it. This is NFC since this flag is currently a no-op.
14 lines
544 B
Swift
14 lines
544 B
Swift
// RUN: %target-typecheck-verify-swift -verify-ignore-unrelated
|
|
|
|
class Dictionary<K, V> : ExpressibleByDictionaryLiteral { // expected-error {{type 'Dictionary<K, V>' does not conform to protocol 'ExpressibleByDictionaryLiteral'}} expected-note {{add stubs for conformance}}
|
|
typealias Key = K
|
|
typealias Value = V
|
|
init(dictionaryLiteral xs: K...){} // expected-note {{candidate has non-matching type '(dictionaryLiteral: K...)'}}
|
|
}
|
|
|
|
func useDict<K, V>(_ d: Dictionary<K,V>) {}
|
|
|
|
useDict(["Hello" : 1])
|
|
useDict(["Hello" : 1, "World" : 2])
|
|
|