Commit a641192
committed
[Concurrency] Handle cases where a property initializer is subsumed by another
property for IsolatedDefaultValues.
For property wrappers and init accesors, skip property initializers that are
subsumed, e.g. by an init accessor or a backing property wrapper initializer,
and always consider the subsuming initializer to determine whether compiler
synthesized initializers should have `nonisolated` applied.
This change also lessens the source break of SE-0411 by still emitting
member initializers in implicit constructors when the initializer violates
actor isolation to preserve the behavior of existing code when concurrency
diagnostics are downgraded to warnings in Swift 5 mode.
(cherry picked from commit 20829fa)1 parent 99e9db8 commit a641192
File tree
5 files changed
+107
-23
lines changed- lib
- SILGen
- Sema
- test/Concurrency
5 files changed
+107
-23
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1544 | 1544 | | |
1545 | 1545 | | |
1546 | 1546 | | |
1547 | | - | |
1548 | | - | |
| 1547 | + | |
| 1548 | + | |
| 1549 | + | |
| 1550 | + | |
| 1551 | + | |
| 1552 | + | |
| 1553 | + | |
| 1554 | + | |
| 1555 | + | |
| 1556 | + | |
| 1557 | + | |
1549 | 1558 | | |
| 1559 | + | |
| 1560 | + | |
1550 | 1561 | | |
1551 | 1562 | | |
1552 | 1563 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
350 | 350 | | |
351 | 351 | | |
352 | 352 | | |
353 | | - | |
| 353 | + | |
354 | 354 | | |
355 | 355 | | |
356 | | - | |
357 | | - | |
358 | | - | |
359 | | - | |
| 356 | + | |
| 357 | + | |
| 358 | + | |
| 359 | + | |
| 360 | + | |
| 361 | + | |
| 362 | + | |
| 363 | + | |
| 364 | + | |
| 365 | + | |
| 366 | + | |
| 367 | + | |
| 368 | + | |
| 369 | + | |
| 370 | + | |
| 371 | + | |
| 372 | + | |
| 373 | + | |
| 374 | + | |
| 375 | + | |
| 376 | + | |
| 377 | + | |
| 378 | + | |
| 379 | + | |
| 380 | + | |
| 381 | + | |
360 | 382 | | |
361 | 383 | | |
362 | 384 | | |
363 | 385 | | |
364 | | - | |
| 386 | + | |
365 | 387 | | |
366 | 388 | | |
367 | | - | |
368 | | - | |
| 389 | + | |
369 | 390 | | |
370 | 391 | | |
371 | 392 | | |
372 | | - | |
373 | | - | |
374 | | - | |
375 | | - | |
376 | | - | |
| 393 | + | |
| 394 | + | |
| 395 | + | |
| 396 | + | |
| 397 | + | |
| 398 | + | |
| 399 | + | |
| 400 | + | |
377 | 401 | | |
378 | 402 | | |
379 | 403 | | |
380 | 404 | | |
| 405 | + | |
381 | 406 | | |
382 | 407 | | |
383 | 408 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
168 | 168 | | |
169 | 169 | | |
170 | 170 | | |
| 171 | + | |
| 172 | + | |
171 | 173 | | |
172 | 174 | | |
173 | 175 | | |
| 176 | + | |
174 | 177 | | |
175 | 178 | | |
176 | 179 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
558 | 558 | | |
559 | 559 | | |
560 | 560 | | |
561 | | - | |
| 561 | + | |
| 562 | + | |
562 | 563 | | |
563 | | - | |
| 564 | + | |
| 565 | + | |
| 566 | + | |
| 567 | + | |
564 | 568 | | |
565 | 569 | | |
566 | 570 | | |
| |||
585 | 589 | | |
586 | 590 | | |
587 | 591 | | |
| 592 | + | |
| 593 | + | |
| 594 | + | |
| 595 | + | |
588 | 596 | | |
589 | 597 | | |
590 | 598 | | |
| |||
669 | 677 | | |
670 | 678 | | |
671 | 679 | | |
| 680 | + | |
672 | 681 | | |
| 682 | + | |
673 | 683 | | |
674 | 684 | | |
675 | 685 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | | - | |
4 | | - | |
5 | 3 | | |
6 | 4 | | |
7 | 5 | | |
| |||
196 | 194 | | |
197 | 195 | | |
198 | 196 | | |
199 | | - | |
| 197 | + | |
200 | 198 | | |
201 | 199 | | |
202 | 200 | | |
203 | | - | |
204 | 201 | | |
205 | 202 | | |
206 | 203 | | |
207 | 204 | | |
208 | 205 | | |
209 | | - | |
| 206 | + | |
210 | 207 | | |
211 | 208 | | |
212 | 209 | | |
213 | | - | |
214 | 210 | | |
215 | 211 | | |
216 | 212 | | |
| |||
229 | 225 | | |
230 | 226 | | |
231 | 227 | | |
| 228 | + | |
| 229 | + | |
| 230 | + | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
| 245 | + | |
| 246 | + | |
| 247 | + | |
| 248 | + | |
| 249 | + | |
| 250 | + | |
| 251 | + | |
| 252 | + | |
| 253 | + | |
| 254 | + | |
| 255 | + | |
| 256 | + | |
| 257 | + | |
| 258 | + | |
| 259 | + | |
| 260 | + | |
| 261 | + | |
| 262 | + | |
| 263 | + | |
| 264 | + | |
| 265 | + | |
| 266 | + | |
0 commit comments