Skip to content

Commit d64ecb8

Browse files
committed
Update documentation for Reflectable
1 parent 88cd4a2 commit d64ecb8

File tree

3 files changed

+12
-0
lines changed

3 files changed

+12
-0
lines changed

crates/bevy_reflect/src/reflect.rs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -399,10 +399,14 @@ where
399399
/// Doing so will automatically implement this trait, [`PartialReflect`], and many other useful traits for reflection,
400400
/// including one of the appropriate subtraits: [`Struct`], [`TupleStruct`] or [`Enum`].
401401
///
402+
/// If you need to use this trait as a generic bound along with other reflection traits,
403+
/// for your convenience, consider using [`Reflectable`] instead.
404+
///
402405
/// See the [crate-level documentation] to see how this trait can be used.
403406
///
404407
/// [`bevy_reflect`]: crate
405408
/// [the derive macro]: bevy_reflect_derive::Reflect
409+
/// [`Reflectable`]: crate::Reflectable
406410
/// [crate-level documentation]: crate
407411
#[diagnostic::on_unimplemented(
408412
message = "`{Self}` does not implement `Reflect` so cannot be fully reflected",

crates/bevy_reflect/src/type_info.rs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,9 @@ use thiserror::Error;
1414
/// This trait is automatically implemented by the [`#[derive(Reflect)]`](derive@crate::Reflect) macro
1515
/// and allows type information to be processed without an instance of that type.
1616
///
17+
/// If you need to use this trait as a generic bound along with other reflection traits,
18+
/// for your convenience, consider using [`Reflectable`] instead.
19+
///
1720
/// # Implementing
1821
///
1922
/// While it is recommended to leave implementing this trait to the `#[derive(Reflect)]` macro,
@@ -81,6 +84,7 @@ use thiserror::Error;
8184
/// # }
8285
/// ```
8386
///
87+
/// [`Reflectable`]: crate::Reflectable
8488
/// [utility]: crate::utility
8589
#[diagnostic::on_unimplemented(
8690
message = "`{Self}` does not implement `Typed` so cannot provide static type information",

crates/bevy_reflect/src/type_registry.rs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,8 +53,12 @@ impl Debug for TypeRegistryArc {
5353
/// This trait is automatically implemented for items using [`#[derive(Reflect)]`](derive@crate::Reflect).
5454
/// The macro also allows [`TypeData`] to be more easily registered.
5555
///
56+
/// If you need to use this trait as a generic bound along with other reflection traits,
57+
/// for your convenience, consider using [`Reflectable`] instead.
58+
///
5659
/// See the [crate-level documentation] for more information on type registration.
5760
///
61+
/// [`Reflectable`]: crate::Reflectable
5862
/// [crate-level documentation]: crate
5963
#[diagnostic::on_unimplemented(
6064
message = "`{Self}` does not implement `GetTypeRegistration` so cannot provide type registration information",

0 commit comments

Comments
 (0)