@@ -52,7 +52,7 @@ type GizmosState<T> = (
5252pub struct GizmosFetchState < T : GizmoConfigGroup > {
5353 state : <GizmosState < T > as SystemParam >:: State ,
5454}
55- // SAFETY: All methods are delegated to existing `SystemParam` implemntations
55+ // SAFETY: All methods are delegated to existing `SystemParam` implementations
5656unsafe impl < T : GizmoConfigGroup > SystemParam for Gizmos < ' _ , ' _ , T > {
5757 type State = GizmosFetchState < T > ;
5858 type Item < ' w , ' s > = Gizmos < ' w , ' s , T > ;
@@ -77,8 +77,10 @@ unsafe impl<T: GizmoConfigGroup> SystemParam for Gizmos<'_, '_, T> {
7777 world : UnsafeWorldCell < ' w > ,
7878 change_tick : Tick ,
7979 ) -> Self :: Item < ' w , ' s > {
80- let ( f0, f1) =
81- GizmosState :: < T > :: get_param ( & mut state. state , system_meta, world, change_tick) ;
80+ // SAFETY: Delegated to existing `SystemParam` implementations
81+ let ( f0, f1) = unsafe {
82+ GizmosState :: < T > :: get_param ( & mut state. state , system_meta, world, change_tick)
83+ } ;
8284 // Accessing the GizmoConfigStore in the immediate mode API reduces performance significantly.
8385 // Implementing SystemParam manually allows us to do it to here
8486 // Having config available allows for early returns when gizmos are disabled
0 commit comments