Update WorldQueryGats doc with type aliases (#5898)
Make API users aware that the type aliases `QueryItem` and `QueryFetch` can be used instead of the more bloated alternative with `WorldQueryGats`. Fixes #5842
This commit is contained in:
parent
bd68ba1c3c
commit
7a92555233
@ -436,7 +436,9 @@ pub unsafe trait WorldQuery: for<'w> WorldQueryGats<'w> {
|
|||||||
) -> bool;
|
) -> bool;
|
||||||
}
|
}
|
||||||
|
|
||||||
/// A helper trait for [`WorldQuery`] that works around Rust's lack of Generic Associated Types
|
/// A helper trait for [`WorldQuery`] that works around Rust's lack of Generic Associated Types.
|
||||||
|
///
|
||||||
|
/// **Note**: Consider using the type aliases [`QueryItem`] and [`QueryFetch`] when using `Item` or `Fetch`.
|
||||||
pub trait WorldQueryGats<'world> {
|
pub trait WorldQueryGats<'world> {
|
||||||
type Item;
|
type Item;
|
||||||
type Fetch;
|
type Fetch;
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user