-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implement QueryData for &Archetype and EntityLocation #12398
Conversation
@urben1680 feel free to live a review here if you're comfortable. |
I would like the two types being mentioned in the
Would the implementation as it is right now here, besides the |
set_archetype is never called on dense fetches, as it's table oriented instead. The Option in the fetch would always be None, and hence the debug_checked_unwrap would always panic or become undefined behavior. If we were instead to take the entity, look up its location, then use its location to look up its archetype, it would work with both, but that would likely be slower in isolation than just returning back the assigned archetype. I'm leaning towards making it dense, as making it force archetypal iteration will likely be slower in any compound query. |
Co-authored-by: Alice Cecile <[email protected]>
Objective
Fixes #12392, fixes #12393, and fixes #11387. Implement QueryData for Archetype and EntityLocation.
Solution
Add impls for both of the types.
Changelog
Added:
&Archetype
now implementsQueryData
Added:
EntityLocation
now implementsQueryData