bevy/crates/bevy_ecs/src
Eagster 61bd3af7c7
Remove invalid entity locations (#19433)
# Objective

This is the first step of #19430 and is a follow up for #19132.

Now that `ArchetypeRow` has a niche, we can use `Option` instead of
needing `INVALID` everywhere.

This was especially concerning since `INVALID` *really was valid!*

Using options here made the code clearer and more data-driven. 

## Solution

Replace all uses of `INVALID` entity locations (and archetype/table
rows) with `None`.

## Testing

CI

---------

Co-authored-by: Chris Russell <8494645+chescock@users.noreply.github.com>
Co-authored-by: François Mockers <francois.mockers@vleue.com>
Co-authored-by: Alice Cecile <alice.i.cecile@gmail.com>
2025-05-31 16:34:33 +00:00
..
entity Remove invalid entity locations (#19433) 2025-05-31 16:34:33 +00:00
error More uninlined_format_args fixes (#19396) 2025-05-28 02:35:18 +00:00
event Remove apostrophes in possessive its (#19244) 2025-05-26 19:53:14 +00:00
observer Remove ArchetypeComponentId and archetype_component_access (#19143) 2025-05-27 19:04:32 +00:00
query Remove ArchetypeComponentId and archetype_component_access (#19143) 2025-05-27 19:04:32 +00:00
reflect Make remove_reflect parameter names consistent between ReflectCommandExt and impl for EntityCommands (#19243) 2025-05-26 19:49:56 +00:00
relationship Fix custom relations panics with parent/child relations (#19341) 2025-05-27 21:05:31 +00:00
schedule Clarify Resource change detection behaviour in condition docs (#19252) 2025-05-30 00:47:25 +00:00
storage Remove invalid entity locations (#19433) 2025-05-31 16:34:33 +00:00
system Remove ArchetypeComponentId and archetype_component_access (#19143) 2025-05-27 19:04:32 +00:00
world Remove invalid entity locations (#19433) 2025-05-31 16:34:33 +00:00
archetype.rs Remove ArchetypeComponentId and archetype_component_access (#19143) 2025-05-27 19:04:32 +00:00
batching.rs Nonmax all rows (#19132) 2025-05-26 17:39:55 +00:00
bundle.rs Remove invalid entity locations (#19433) 2025-05-31 16:34:33 +00:00
change_detection.rs Fix EntityMeta.spawned_or_despawned unsoundness (#19350) 2025-05-27 22:45:07 +00:00
component.rs refactor(utils): move SyncCell and SyncUnsafeCell to bevy_platform (#19305) 2025-05-27 04:57:26 +00:00
entity_disabling.rs bevy_reflect: Add clone registrations project-wide (#18307) 2025-03-17 18:32:35 +00:00
hierarchy.rs More uninlined_format_args fixes (#19396) 2025-05-28 02:35:18 +00:00
intern.rs Rename bevy_platform_support to bevy_platform (#18813) 2025-04-11 23:13:28 +00:00
label.rs Remove upcasting methods + Cleanup interned label code (#18984) 2025-05-26 15:38:12 +00:00
lib.rs Remove ArchetypeComponentId and archetype_component_access (#19143) 2025-05-27 19:04:32 +00:00
name.rs Make entity generation a new type and remove identifier (#19121) 2025-05-08 04:03:05 +00:00
never.rs Use never_say_never hack to work around Rust 2024 regression for fn traits (#18804) 2025-04-14 19:59:48 +00:00
removal_detection.rs bevy_reflect: Add clone registrations project-wide (#18307) 2025-03-17 18:32:35 +00:00
resource.rs refactor(utils): move SyncCell and SyncUnsafeCell to bevy_platform (#19305) 2025-05-27 04:57:26 +00:00
spawn.rs Increase upper limit of children! (#18865) 2025-05-06 00:58:30 +00:00
traversal.rs Add missing words in Traversal doc comment (#19298) 2025-05-19 19:34:59 +00:00