[SR-11803] Don't inject "willThrow" hooks before rethrow propagation branches #54213
Labels
bug
A deviation from expected or documented behavior. Also: expected but undesirable behavior.
compiler
The Swift compiler in itself
good first issue
Good for newcomers
Additional Detail from JIRA
md5: 5bcb9cad814df2dd1cc8124f822c3e34
Issue Description:
LLDB has a magic symbol it's looking for in order to implement Swift exception breakpoints. That symbol is "willThrow" in SIL and it's implemented with "swift_willThrow" in IRGen. The trouble is that we're a little too aggressive about emitting calls to this hook. Joe has already identified the places we don't need it in #13585
Step one is to take that PR, rebase it, and rerun the tests to make sure everything is good. The real task is to take that pull request and do the opposite where we propagate Objective-C errors into Swift. The logic for this sits in SILGenForeignError.cpp. There should also be an IRGen test to make sure we emit the right set of branches, cleanups, and error propagation code.
The text was updated successfully, but these errors were encountered: