-
Notifications
You must be signed in to change notification settings - Fork 221
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
93: FlaggedStorage r=torkleyy A basic implementation for a `TrackedStorage` (#89). This version of the `TrackedStorage` does not implement a way to compare the past version and the modifies version of the components. Usage requires unwrapping the storage to the base `TrackedStorage` which implements `Join` for flagged components. ### Alternative design choices: **Implement `TrackedStorage` similar to how `MaskedStorage` works.** _Pros:_ - Would make it possible to have the `Join` of the storage only work on the flagged components without calling any additional methods. - Might open up a path for a generic storage wrapper like `UnprotectedStorage` but instead as a container for how the `Join` gets the components necessary for the loop (this could be interesting since it would allow for different methods other than bitsets, but would also be pretty hard to get right). _Cons:_ - Difficult to get all the components instead of just the flagged ones as there is no current way to directly get access to the container storage. - Might be unintuitive at a glance as you would expect to get all the components when joining the storage. **Compare modifications for more accurate flags** _Pros:_ - Removes a large concern for if the user iterates over a mutable tracked storage. _Cons:_ - Performance benefits of the tracked storage decreases. - Difficult to implement. Requires a way to directly compare the new "modified" version with the past version.
- Loading branch information
Showing
5 changed files
with
238 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters