Skip to content

Commit 26318c9

Browse files
committed
docs(ref): Move target-edition to last
1 parent 340d123 commit 26318c9

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

src/doc/src/reference/cargo-targets.md

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -186,9 +186,10 @@ bench = true # Is benchmarked by default.
186186
doc = true # Is documented by default.
187187
proc-macro = false # Set to `true` for a proc-macro library.
188188
harness = true # Use libtest harness.
189-
edition = "2015" # The edition of the target.
190189
crate-type = ["lib"] # The crate types to generate.
191190
required-features = [] # Features required to build this target (N/A for lib).
191+
192+
edition = "2015" # The edition of the target.
192193
```
193194

194195
### The `name` field
@@ -268,14 +269,6 @@ to run tests and benchmarks.
268269
Tests have the [`cfg(test)` conditional expression][cfg-test] enabled whether
269270
or not the harness is enabled.
270271

271-
### The `edition` field
272-
273-
The `edition` field defines the [Rust edition] the target will use. If not
274-
specified, it defaults to the [`edition` field][package-edition] for the
275-
`[package]`. This field should usually not be set, and is only intended for
276-
advanced scenarios such as incrementally transitioning a large package to a
277-
new edition.
278-
279272
### The `crate-type` field
280273

281274
The `crate-type` field defines the [crate types] that will be generated by the
@@ -313,6 +306,13 @@ name = "my-pg-tool"
313306
required-features = ["postgres", "tools"]
314307
```
315308

309+
### The `edition` field
310+
311+
The `edition` field defines the [Rust edition] the target will use. If not
312+
specified, it defaults to the [`edition` field][package-edition] for the
313+
`[package]`. This field should usually not be set, and is only intended for
314+
advanced scenarios such as incrementally transitioning a large package to a
315+
new edition.
316316

317317
## Target auto-discovery
318318

0 commit comments

Comments
 (0)