mirror of
https://github.com/github/semantic.git
synced 2024-11-25 21:43:07 +03:00
9 lines
236 B
Swift
9 lines
236 B
Swift
extension Dictionary {
|
|
public init<C: CollectionType where C.Generator.Element == (Key, Value)>(elements: C) {
|
|
self.init(minimumCapacity: Int(elements.count.toIntMax()))
|
|
for (key, value) in elements {
|
|
self[key] = value
|
|
}
|
|
}
|
|
}
|