File tree Expand file tree Collapse file tree 1 file changed +16
-0
lines changed Expand file tree Collapse file tree 1 file changed +16
-0
lines changed Original file line number Diff line number Diff line change @@ -26,6 +26,21 @@ CHANGELOG
26
26
Swift 5.2
27
27
---------
28
28
29
+ * [ SR-2189] [ ] :
30
+
31
+ The compiler now supports local functions whose default arguments capture
32
+ values from outer scopes.
33
+
34
+ ``` swift
35
+ func outer (x : Int ) -> (Int , Int ) {
36
+ func inner (y : Int = x) -> Int {
37
+ return y
38
+ }
39
+
40
+ return (inner (), inner (y : 0 ))
41
+ }
42
+ ```
43
+
29
44
* [ SR-11429] [ ] :
30
45
31
46
The compiler will now correctly strip argument labels from function references
@@ -7803,6 +7818,7 @@ Swift 1.0
7803
7818
[SR- 1529 ]: < https: // bugs.swift.org/browse/SR-1529>
7804
7819
[SR- 2131 ]: < https: // bugs.swift.org/browse/SR-2131>
7805
7820
[SR- 2176 ]: < https: // bugs.swift.org/browse/SR-2176>
7821
+ [SR- 2189 ]: < https: // bugs.swift.org/browse/SR-2189>
7806
7822
[SR- 2388 ]: < https: // bugs.swift.org/browse/SR-2388>
7807
7823
[SR- 2394 ]: < https: // bugs.swift.org/browse/SR-2394>
7808
7824
[SR- 2608 ]: < https: // bugs.swift.org/browse/SR-2608>
You can’t perform that action at this time.
0 commit comments