bevy/crates/bevy_ecs/src/query
TheBigCheese b1273d48cb
Enable clippy::check-private-items so that missing_safety_doc will apply to private functions as well (#15161)
Enabled `check-private-items` in `clippy.toml` and then fixed the
resulting errors. Most of these were simply misformatted and of the
remaining:
- ~Added `#[allow(clippy::missing_safety_doc)]` to~ Removed unsafe from
a pair of functions in `bevy_utils/futures` which are only unsafe so
that they can be passed to a function which requires `unsafe fn`
- Removed `unsafe` from `UnsafeWorldCell::observers` as from what I can
tell it is always safe like `components`, `bundles` etc. (this should be
checked)
- Added safety docs to:
- `Bundles::get_storage_unchecked`: Based on the function that writes to
`dynamic_component_storages`
- `Bundles::get_storages_unchecked`: Based on the function that writes
to `dynamic_bundle_storages`
   - `QueryIterationCursor::init_empty`: Duplicated from `init`
- `QueryIterationCursor::peek_last`: Thanks Giooschi (also added
internal unsafe blocks)
   - `tests::drop_ptr`: Moved safety comment out to the doc string
 
This lint would also apply to `missing_errors_doc`, `missing_panics_doc`
and `unnecessary_safety_doc` if we chose to enable any of those at some
point, although there is an open
[issue](https://github.com/rust-lang/rust-clippy/issues/13074) to
separate these options.
2024-09-18 15:28:41 +00:00
..
access.rs Add EntityRefExcept and EntityMutExcept world queries, in preparation for generalized animation. (#15207) 2024-09-17 14:53:39 +00:00
builder.rs Add EntityRefExcept and EntityMutExcept world queries, in preparation for generalized animation. (#15207) 2024-09-17 14:53:39 +00:00
error.rs Remove APIs deprecated in 0.13 (#11974) 2024-02-19 19:04:47 +00:00
fetch.rs Add EntityRefExcept and EntityMutExcept world queries, in preparation for generalized animation. (#15207) 2024-09-17 14:53:39 +00:00
filter.rs Remove redundent information and optimize dynamic allocations in Table (#12929) 2024-09-16 22:52:05 +00:00
iter.rs Enable clippy::check-private-items so that missing_safety_doc will apply to private functions as well (#15161) 2024-09-18 15:28:41 +00:00
mod.rs Remove redundent information and optimize dynamic allocations in Table (#12929) 2024-09-16 22:52:05 +00:00
par_iter.rs Fix query transmute from table to archetype iteration unsoundness (#14615) 2024-08-27 00:58:40 +00:00
state.rs Enable clippy::check-private-items so that missing_safety_doc will apply to private functions as well (#15161) 2024-09-18 15:28:41 +00:00
world_query.rs Add query reborrowing (#14690) 2024-08-15 17:38:56 +00:00