Skip to content

Commit

Permalink
fix a doctest
Browse files Browse the repository at this point in the history
Signed-off-by: TennyZhuang <[email protected]>
  • Loading branch information
TennyZhuang committed Oct 16, 2022
1 parent abd5db3 commit 360b48b
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 12 deletions.
12 changes: 6 additions & 6 deletions clippy_lints/src/partial_pub_fields.rs
Original file line number Diff line number Diff line change
Expand Up @@ -18,17 +18,17 @@ declare_clippy_lint! {
/// ### Example
/// ```rust
/// pub struct Color {
/// pub r,
/// pub g,
/// b,
/// pub r: u8,
/// pub g: u8,
/// b: u8,
/// }
/// ```
/// Use instead:
/// ```rust
/// pub struct Color {
/// pub r,
/// pub g,
/// pub b,
/// pub r: u8,
/// pub g: u8,
/// pub b: u8,
/// }
/// ```
#[clippy::version = "1.66.0"]
Expand Down
12 changes: 6 additions & 6 deletions src/docs/partial_pub_fields.txt
Original file line number Diff line number Diff line change
Expand Up @@ -12,16 +12,16 @@ interior invariants and expose intentionally limited API to the outside world.
### Example
```
pub struct Color {
pub r,
pub g,
b,
pub r: u8,
pub g: u8,
b: u8,
}
```
Use instead:
```
pub struct Color {
pub r,
pub g,
pub b,
pub r: u8,
pub g: u8,
pub b: u8,
}
```

0 comments on commit 360b48b

Please sign in to comment.