[SR-14287] Dictionary(uniqueKeysWithValues:) cannot accept KeyValuePairs #56646
Labels
bug
A deviation from expected or documented behavior. Also: expected but undesirable behavior.
compiler
The Swift compiler in itself
type checker
Area → compiler: Semantic analysis
Environment
Xcode 12.5 beta 2
Swift version 5.4 (swiftlang-1205.0.24.6 clang-1205.0.19.54).
Additional Detail from JIRA
md5: 16f594c0f1d796dd9c1e8bdb575f6220
Issue Description:
KeyValuesPairs is a Sequence whose Element is (key: Key, value: Value). It should be acceptable to Dictionary(uniqueKeysWithValues). Arrays with the same Element are acceptable.
This feels like an error in the type checker rather than an error in stdlib.
The text was updated successfully, but these errors were encountered: