Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit cdfb586

Browse files
committed
Parameter labels removed from Dictionary extensions
1 parent e0848c9 commit cdfb586

File tree

4 files changed

+11
-814
lines changed

4 files changed

+11
-814
lines changed

‎ExSwift/Dictionary.swift

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ internal extension Dictionary {
8080
}
8181

8282
// Intersection
83-
return filtered.filter(testFunction:{ (key: K, value: V) -> Bool in
83+
return filtered.filter({ (key: K, value: V) -> Bool in
8484
// check for [key: value] in all the dictionaries
8585
dictionaries.all { 0ドル.has(key) && 0ドル[key] == value }
8686
})
@@ -104,7 +104,7 @@ internal extension Dictionary {
104104
:param: mapFunction
105105
:returns: Mapped array
106106
*/
107-
func toArray <V> (mapFunction map: (Key, Value) -> V) -> [V] {
107+
func toArray <V> (map: (Key, Value) -> V) -> [V] {
108108

109109
var mapped = [V]()
110110

@@ -123,7 +123,7 @@ internal extension Dictionary {
123123
:param: mapFunction
124124
:returns: Mapped dictionary
125125
*/
126-
func mapValues <V> (mapFunction map: (Key, Value) -> V) -> [Key: V] {
126+
func mapValues <V> (map: (Key, Value) -> V) -> [Key: V] {
127127

128128
var mapped = [Key: V]()
129129

@@ -142,7 +142,7 @@ internal extension Dictionary {
142142
:param: mapFunction
143143
:returns: Mapped dictionary
144144
*/
145-
func mapFilterValues <V> (mapFunction map: (Key, Value) -> V?) -> [Key: V] {
145+
func mapFilterValues <V> (map: (Key, Value) -> V?) -> [Key: V] {
146146

147147
var mapped = [Key: V]()
148148

@@ -163,7 +163,7 @@ internal extension Dictionary {
163163
:param: mapFunction
164164
:returns: Mapped dictionary
165165
*/
166-
func mapFilter <K, V> (mapFunction map: (Key, Value) -> (K, V)?) -> [K: V] {
166+
func mapFilter <K, V> (map: (Key, Value) -> (K, V)?) -> [K: V] {
167167

168168
var mapped = [K: V]()
169169

@@ -184,11 +184,11 @@ internal extension Dictionary {
184184
:param: mapFunction
185185
:returns: Mapped dictionary
186186
*/
187-
func map <K, V> (mapFunction map: (Key, Value) -> (K, V)) -> [K: V] {
187+
func map <K, V> (map: (Key, Value) -> (K, V)) -> [K: V] {
188188

189189
var mapped = [K: V]()
190190

191-
self.each(eachFunction:{
191+
self.each({
192192
let (_key, _value) = map(0ドル, 1ドル)
193193
mapped[_key] = _value
194194
})
@@ -202,7 +202,7 @@ internal extension Dictionary {
202202

203203
:param: eachFunction Function to inovke on each loop
204204
*/
205-
func each (eachFunction each: (Key, Value) -> ()) {
205+
func each (each: (Key, Value) -> ()) {
206206

207207
for (key, value) in self {
208208
each(key, value)
@@ -217,7 +217,7 @@ internal extension Dictionary {
217217
:param: testFunction Function called to test each key, value
218218
:returns: Filtered dictionary
219219
*/
220-
func filter (testFunction test: (Key, Value) -> Bool) -> Dictionary {
220+
func filter (test: (Key, Value) -> Bool) -> Dictionary {
221221

222222
var result = Dictionary()
223223

@@ -239,7 +239,7 @@ internal extension Dictionary {
239239
:param: groupingFunction
240240
:returns: Grouped dictionary
241241
*/
242-
func groupBy <T> (groupingFunction group: (Key, Value) -> T) -> [T: [Value]] {
242+
func groupBy <T> (group: (Key, Value) -> T) -> [T: [Value]] {
243243

244244
var result = [T: [Value]]()
245245

@@ -265,7 +265,7 @@ internal extension Dictionary {
265265
:param: groupingFunction Function called to define the grouping key
266266
:returns: Grouped dictionary
267267
*/
268-
func countBy <T> (groupingFunction group: (Key, Value) -> (T)) -> [T: Int] {
268+
func countBy <T> (group: (Key, Value) -> (T)) -> [T: Int] {
269269

270270
var result = [T: Int]()
271271

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /