bevy
bevy copied to clipboard
Add `EntityMut::get_mut_by_id_unchecked`
I still think there should be a
get_mut_by_id_unchecked. The apis added in #15593 could end up allocating in some tight loops which would be a perf footgun. The unchecked version would allow users to implement their own versions in userspace that could reuse the allocations.
Originally posted by @hymm in #15577
I intend to work on this if no one else gets to it first
it was also suggested that a variant checking unicity though a hashset could be better: https://github.com/bevyengine/bevy/issues/15577#issuecomment-2387108509