bevy/crates/bevy_ecs/src
KDecay 506642744c docs: Fix private doc links and enable CI test (#3743)
# Objective

Fixes #3566

## Solution

- [x] Fix broken links in private docs.
- [x] Add the `--document-private-items` flag to the CI.

## Note

The following was said by @killercup in #3566:

> I don't have time to confirm this but I assume that linking to private items throws an error/warning when just running cargo doc, and --document-private-item might actually hide that warning. So to test this, you'd have to run it twice.

I tested this and this is thankfully not the case. If you are linking to a private item you will get a warning no matter if you run `cargo doc` or `cargo doc --document-private-items`.

### Example

I added `struct Test;` to `bevy_core/src/name.rs` and linked to it inside of a doc comment using ``[`Test`]``. After that I ran `cargo doc -p bevy_core --document-private-items` using `RUSTDOCFLAGS="-D warnings"` and got the following output (note the last sentence):

```rust
error: public documentation for `Name` links to private item `Test`
  --> crates/bevy_core/src/name.rs:11:82
   |
11 | /// Component used to identify an entity. Stores a hash for faster comparisons [`Test`]
   |                                                                                  ^^^^ this item is private
   |
   = note: `-D rustdoc::private-intra-doc-links` implied by `-D warnings`
   = note: this link resolves only because you passed `--document-private-items`, but will break without
```
2022-02-02 21:47:29 +00:00
..
entity Fix doc_markdown lints in bevy_ecs (#3473) 2022-01-06 00:43:37 +00:00
query docs: Fix private doc links and enable CI test (#3743) 2022-02-02 21:47:29 +00:00
schedule Add missing closing ticks for inline examples and some cleanup (#3573) 2022-01-07 09:25:12 +00:00
storage Fix doc_markdown lints in bevy_ecs (#3473) 2022-01-06 00:43:37 +00:00
system Mark .id() methods which return an Entity as must_use (#3750) 2022-01-23 14:24:37 +00:00
world docs: Fix private doc links and enable CI test (#3743) 2022-02-02 21:47:29 +00:00
archetype.rs Fix doc_markdown lints in bevy_ecs (#3473) 2022-01-06 00:43:37 +00:00
bundle.rs Fix doc_markdown lints in bevy_ecs (#3473) 2022-01-06 00:43:37 +00:00
change_detection.rs default features from bevy_asset and bevy_ecs can actually be disabled (#3097) 2021-11-13 21:15:22 +00:00
component.rs Remove ComponentsError (#3716) 2022-01-21 00:12:32 +00:00
event.rs Increment last event count on next instead of iter (#2382) 2022-02-02 02:29:33 +00:00
lib.rs Mark .id() methods which return an Entity as must_use (#3750) 2022-01-23 14:24:37 +00:00
reflect.rs Add FromReflect trait to convert dynamic types to concrete types (#1395) 2021-12-26 18:49:01 +00:00