Add NonNilUuid support to bevy_reflect (#18604)

# Objective

- If using a `NonNilUuid` in Bevy, it's difficult to reflect it.

## Solution

- Adds `NonNilUuid` using `impl_reflect_opaque!`.

## Testing

- Built with no issues found locally.
- Essentially the same as the `Uuid` support except without `Default`.

Co-authored-by: TM Storey <mail@tmstorey.id.au>
This commit is contained in:
tmstorey 2025-05-04 18:22:57 +10:00 committed by GitHub
parent 5e2ecf4178
commit c55c69e3fc
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -10,3 +10,12 @@ impl_reflect_opaque!(::uuid::Uuid(
PartialEq,
Hash
));
impl_reflect_opaque!(::uuid::NonNilUuid(
Serialize,
Deserialize,
Clone,
Debug,
PartialEq,
Hash
));