Commit Graph

9 Commits

Author SHA1 Message Date
Alexander Cyon
c18a24e499 [SwiftCompilerSources] Fix typos 2024-08-08 22:22:39 -07:00
Andrew Trick
11ba799cd4 LifetimeDependence: diagnose yield and store-to-yield. 2024-07-30 16:27:48 -07:00
Andrew Trick
c41dc33c10 LocalVariableUtils: handle projections inside initializers.
These projections don't have access scopes, so the utility was treating them
like escapes.

Fixes: rdar://131499478 (Difficulties composing non-escapable types)
2024-07-12 19:58:14 -07:00
Andrew Trick
fc60925a38 LocalVariableUtils: add support for temporary enum initialization. 2024-04-12 14:11:37 -07:00
Andrew Trick
e77fff3d23 LocalVariableUtils logging 2024-03-18 17:45:33 -07:00
Andrew Trick
f1fbbcd438 Handle escaping addresses in LocalVariableAccessWalker
Fixes rdar://124564951 (Compiler crash when evaluating pointer escape
in autoclosure; LifetimeDepenenceScopeFixup; Fatal error: check
findPointerEscape() before computing interior liveness.)
2024-03-18 17:45:33 -07:00
Andrew Trick
00fbf4f1af LocalVariableUtils logging 2024-03-18 17:45:33 -07:00
Andrew Trick
aa208bbf91 Add SILType::containsNoEscapeFunction()
Add PartialApplyInst.hasNoescapeCapture
Add PartialApplyInst.mayEscape

Refactor DiagnoseInvalidEscapingCaptures. This may change functionality because tuples containing a noescape closure are now correctly recognized. Although I'm not sure such tupes can ever be captured directly.
2024-03-18 17:38:12 -07:00
Andrew Trick
ffe9c48976 Add LocalVariableUtils
This includes a reaching-def analysis that can be used by diagnostic passes. Diagnostics should be flow-sensitive.
2024-03-05 18:08:16 -08:00