-
Notifications
You must be signed in to change notification settings - Fork 10.5k
[region-isolation] Improve async let errors to always use a new style error. #74869
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
…n also work with TransferNonSendable versions of the error. This asserts only option is an option to make it quicker/easier to triage unknown pattern match errors by aborting when we emit it (allowing one to immediately drop into the debugger at that point). Previously, it only happened for errors in RegionAnalysis not in TransferNonSendable itself.
… not further sent into an actor isolated function to use a new style error. Just going through and fixing sending errors. rdar://130915737
…oved cleanup transfernonsendable_asynclet.swift. NFC.
@swift-ci smoke test |
#ifndef NDEBUG | ||
/// Global bool set only when asserts are enabled to ease debugging by causing | ||
/// unknown pattern errors to cause an assert so we drop into the debugger. | ||
extern bool AbortOnUnknownPatternMatchError; | ||
#endif | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The code in TransferNonSendable.cpp
that uses AbortOnUnknownPatternMatchError
is not guarded by NDEBUG
.
swift/lib/SILOptimizer/Mandatory/TransferNonSendable.cpp
Lines 681 to 684 in 3ccbcfe
if (AbortOnUnknownPatternMatchError) { | |
llvm::report_fatal_error( | |
"RegionIsolation: Aborting on unknown pattern match error"); | |
} |
swift/lib/SILOptimizer/Mandatory/TransferNonSendable.cpp
Lines 1098 to 1101 in 3ccbcfe
if (AbortOnUnknownPatternMatchError) { | |
llvm::report_fatal_error( | |
"RegionIsolation: Aborting on unknown pattern match error"); | |
} |
swift/lib/SILOptimizer/Mandatory/TransferNonSendable.cpp
Lines 1161 to 1164 in 3ccbcfe
if (AbortOnUnknownPatternMatchError) { | |
llvm::report_fatal_error( | |
"RegionIsolation: Aborting on unknown pattern match error"); | |
} |
swift/lib/SILOptimizer/Mandatory/TransferNonSendable.cpp
Lines 1651 to 1654 in 3ccbcfe
if (AbortOnUnknownPatternMatchError) { | |
llvm::report_fatal_error( | |
"RegionIsolation: Aborting on unknown pattern match error"); | |
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@drodriguez Thanks for the report! I am fixing it here: #74911
Just doing a go over of some of the diagnostics.
rdar://130915737