Commit d8be24b
committed
Sema: Fix -disable-availability-checking.
Suppression of diagnostics about use of unavailable declarations in
equivalently unavailable contexts now relies on querying the
`TypeRefinementContext` hierarchy. Generation of the TypeRefinementContext tree
was suppressed when `-disable-availability-checking` was specified, though,
causing some unavailability diagnostics to be emitted when they ought to be
suppressed.
Instead of refusing to generate a `TypeRefinementContext` hierarchy, instead
just avoid populating nodes for `if #available` checks for OS versions since
these checks are meant to have no effect when `-disable-availability-checking`
is specified.
Resolves rdar://138987918.1 parent 09af72e commit d8be24b
File tree
3 files changed
+32
-17
lines changed- lib/Sema
- test/ModuleInterface
3 files changed
+32
-17
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
238 | 238 | | |
239 | 239 | | |
240 | 240 | | |
241 | | - | |
242 | | - | |
243 | | - | |
244 | | - | |
| 241 | + | |
| 242 | + | |
245 | 243 | | |
246 | 244 | | |
247 | 245 | | |
| |||
259 | 257 | | |
260 | 258 | | |
261 | 259 | | |
262 | | - | |
263 | | - | |
264 | | - | |
265 | | - | |
| 260 | + | |
266 | 261 | | |
267 | 262 | | |
268 | 263 | | |
| |||
1075 | 1070 | | |
1076 | 1071 | | |
1077 | 1072 | | |
| 1073 | + | |
| 1074 | + | |
1078 | 1075 | | |
1079 | 1076 | | |
1080 | 1077 | | |
| |||
1346 | 1343 | | |
1347 | 1344 | | |
1348 | 1345 | | |
| 1346 | + | |
| 1347 | + | |
| 1348 | + | |
| 1349 | + | |
| 1350 | + | |
| 1351 | + | |
| 1352 | + | |
| 1353 | + | |
| 1354 | + | |
| 1355 | + | |
| 1356 | + | |
1349 | 1357 | | |
1350 | | - | |
1351 | 1358 | | |
1352 | 1359 | | |
1353 | 1360 | | |
| |||
1376 | 1383 | | |
1377 | 1384 | | |
1378 | 1385 | | |
1379 | | - | |
1380 | | - | |
1381 | | - | |
1382 | 1386 | | |
1383 | 1387 | | |
1384 | 1388 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
276 | 276 | | |
277 | 277 | | |
278 | 278 | | |
279 | | - | |
280 | | - | |
281 | | - | |
282 | | - | |
283 | | - | |
| 279 | + | |
| 280 | + | |
| 281 | + | |
284 | 282 | | |
285 | 283 | | |
286 | 284 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
0 commit comments