bevy/crates/bevy_hierarchy/src
BD103 aa2ebbb43f
Fix some nightly Clippy lints (#12927)
# Objective

- I daily drive nightly Rust when developing Bevy, so I notice when new
warnings are raised by `cargo check` and Clippy.
- `cargo +nightly clippy` raises a few of these new warnings.

## Solution

- Fix most warnings from `cargo +nightly clippy`
- I skipped the docs-related warnings because some were covered by
#12692.
- Use `Clone::clone_from` in applicable scenarios, which can sometimes
avoid an extra allocation.
- Implement `Default` for structs that have a `pub const fn new() ->
Self` method.
- Fix an occurrence where generic constraints were defined in both `<C:
Trait>` and `where C: Trait`.
  - Removed generic constraints that were implied by the `Bundle` trait.

---

## Changelog

- `BatchingStrategy`, `NonGenericTypeCell`, and `GenericTypeCell` now
implement `Default`.
2024-04-13 02:05:38 +00:00
..
components Disentangle bevy_utils/bevy_core's reexported dependencies (#12313) 2024-03-07 02:30:15 +00:00
child_builder.rs Fix some nightly Clippy lints (#12927) 2024-04-13 02:05:38 +00:00
events.rs Require #[derive(Event)] on all Events (#7086) 2023-06-06 14:44:32 +00:00
hierarchy.rs Move commands module into bevy::ecs::world (#12234) 2024-03-02 23:13:45 +00:00
lib.rs Forbid unsafe in most crates in the engine (#12684) 2024-03-27 03:30:08 +00:00
query_extension.rs Rename Q type parameter to D when referring to WorldQueryData (#10782) 2023-12-13 18:50:46 +00:00
valid_parent_check_plugin.rs Add entity id to hierarchy propagation error message (#12733) 2024-03-26 15:20:21 +00:00