Rollup merge of #33253 - ergenekonyigit:master, r=alexcrichton
rustdoc: fixed some RFCs r? @alexcrichton
This commit is contained in:
commit
3a0efffc9d
2 changed files with 21 additions and 3 deletions
|
@ -1,4 +1,4 @@
|
||||||
% Comments [FIXME: needs RFC]
|
% Comments [RFC #505]
|
||||||
|
|
||||||
### Avoid block comments.
|
### Avoid block comments.
|
||||||
|
|
||||||
|
@ -74,7 +74,25 @@ For example:
|
||||||
|
|
||||||
### Code snippets
|
### Code snippets
|
||||||
|
|
||||||
> **[FIXME]**
|
Only use inner doc comments `//!` to write crate and module-level documentation,
|
||||||
|
nothing else. When using `mod` blocks, prefer `///` outside of the block:
|
||||||
|
|
||||||
|
```rust
|
||||||
|
/// This module contains tests
|
||||||
|
mod test {
|
||||||
|
// ...
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
over
|
||||||
|
|
||||||
|
```rust
|
||||||
|
mod test {
|
||||||
|
//! This module contains tests
|
||||||
|
|
||||||
|
// ...
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
### Avoid inner doc comments.
|
### Avoid inner doc comments.
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
## `return` [FIXME: needs RFC]
|
## `return` [RFC #968]
|
||||||
|
|
||||||
Terminate `return` statements with semicolons:
|
Terminate `return` statements with semicolons:
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue