Skip to content

Commit afa22d6

Browse files
committed
Remove unnecessary indentation in rustdoc book codeblock.
1 parent 748c549 commit afa22d6

File tree

1 file changed

+19
-19
lines changed

1 file changed

+19
-19
lines changed

src/doc/rustdoc/src/documentation-tests.md

+19-19
Original file line numberDiff line numberDiff line change
@@ -138,31 +138,31 @@ To keep each code block testable, we want the whole program in each block, but
138138
we don't want the reader to see every line every time. Here's what we put in
139139
our source code:
140140
141-
```text
142-
First, we set `x` to five:
141+
``````markdown
142+
First, we set `x` to five:
143143
144-
```
145-
let x = 5;
146-
# let y = 6;
147-
# println!("{}", x + y);
148-
```
144+
```
145+
let x = 5;
146+
# let y = 6;
147+
# println!("{}", x + y);
148+
```
149149
150-
Next, we set `y` to six:
150+
Next, we set `y` to six:
151151
152-
```
153-
# let x = 5;
154-
let y = 6;
155-
# println!("{}", x + y);
156-
```
152+
```
153+
# let x = 5;
154+
let y = 6;
155+
# println!("{}", x + y);
156+
```
157157
158-
Finally, we print the sum of `x` and `y`:
158+
Finally, we print the sum of `x` and `y`:
159159
160-
```
161-
# let x = 5;
162-
# let y = 6;
163-
println!("{}", x + y);
164-
```
165160
```
161+
# let x = 5;
162+
# let y = 6;
163+
println!("{}", x + y);
164+
```
165+
``````
166166
167167
By repeating all parts of the example, you can ensure that your example still
168168
compiles, while only showing the parts that are relevant to that part of your

0 commit comments

Comments
 (0)