mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
The recursivelyDeleteTriviallyDeadInstructions utility takes a callBack to be called for every deleted instruction. However, it wasn't passing this callBack to eraseFromParentWithdebugInsts. The callback was used to update an iterator in some cases, so not calling it resulted in iterator invalidation. Doing this also cleans up the both APIs: recursivelyDeleteTriviallyDeadInstructions and eraseFromParentWithdebugInsts.
25 KiB
25 KiB