Revert #1784: Resolve binding key path crash #1799
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
While #1784 manages to work around a longstanding bug in SwiftUI, it unfortunately seems to introduce another one, as found in #1798. In the interest of addressing this regression with a patch release, let's revert things and re-evaluate if the problem is fixable.
@barabashd If you'd like to explore a fix that manages to avoid the crash in #1798, please let us know what you find! As for the original crash you encountered, it was mainly due to what we believe is a bug in Apple's SwiftUI framework. We actually provide a tool to work around this bug, called
ForEachStore
, which allows you to compose into an array of features in a fashion similar to the ad hoc approach you took in your demo app.Fixes #1798.