Jakob Hellermann
Jakob Hellermann
> What's the motivation for a read-only interior ~mutable~ world? Couldn't you just use `&World` for that? If you have an unsafe method that takes a `InteriorMutableWorld` and want to...
Because it can also be used by other methods with write access. Stuff like this: https://github.com/bevyengine/bevy/blob/2938792c7d77ef2777909ac485b0042eb9fe634b/crates/bevy_ecs/src/query/state.rs#L1147 `get_single_unchecked_manual` is used by both `get_single` and `get_single_mut`.
Rebased and addressed comments. > EntityMut::get_mut is implemented by itself rather than calling into InteriorMutableEntityRef Should every method be implemented in terms of `InteriorMutableEntityRef` if possible? Currently, some methods returning...
Okay, I rebased, added the safety comment and renamed `InteriorMutableWorld` -> `UnsafeWorldCell` `InteriorMutableEntityRef` -> `UnsafeEntityRefCell` `as_interior_mutable` -> `as_unsafe_world_cell`.
Generic types should not have a single static UUID.
I also tried using the nightly `generators` feature, but unfortunately I don't think that can work. ```rust || { let (asset_server, images) = yield; // do stuff let (_asset_server, _images)...
> I'd like to see PR description and title updated + the nit addressed before we merge. Done
CI is green
> The PR description seems very out of date to me, the motivation is basically invalidated by the existence of `MutUntyped::with_type` which would let you write code as `untyped.with_type::().map_unchanged(|data| ...)`...