File tree Expand file tree Collapse file tree 1 file changed +7
-3
lines changed
crates/bevy_ecs/src/schedule/executor Expand file tree Collapse file tree 1 file changed +7
-3
lines changed Original file line number Diff line number Diff line change @@ -448,9 +448,13 @@ impl ExecutorState {
448448 }
449449
450450 #[ cfg( feature = "hotpatching" ) ]
451- // SAFETY: This operation is not safe. It could create UB if a user creates a mutable reference
452- // to `HotPatchChanges` in a system. But this can only happen when the `hotpatching` feature is
453- // enabled.
451+ #[ expect(
452+ clippy:: undocumented_unsafe_blocks,
453+ reason = "This actually could result in UB if a system tries to mutate
454+ `HotPatchChanges`. We allow this as the resource only exists with the `hotpatching` feature.
455+ and `hotpatching` should never be enabled in release."
456+ ) ]
457+ #[ cfg( feature = "hotpatching" ) ]
454458 let hotpatch_tick = unsafe {
455459 context
456460 . environment
You can’t perform that action at this time.
0 commit comments