From ac79c41edc2ed9d7125009dd5f21bdcc9fecb3c8 Mon Sep 17 00:00:00 2001 From: steveklabnik Date: Mon, 23 Apr 2018 11:58:11 -0400 Subject: [PATCH] review nits --- src/doc/rustc/src/codegen-options/index.md | 4 ++-- src/doc/rustc/src/lints/levels.md | 4 ++-- src/doc/rustc/src/lints/listing/deny-by-default.md | 2 +- src/doc/rustc/src/targets/index.md | 7 +++---- 4 files changed, 8 insertions(+), 9 deletions(-) diff --git a/src/doc/rustc/src/codegen-options/index.md b/src/doc/rustc/src/codegen-options/index.md index 70dae9314c1..eff09428902 100644 --- a/src/doc/rustc/src/codegen-options/index.md +++ b/src/doc/rustc/src/codegen-options/index.md @@ -99,7 +99,7 @@ flag will turn that behavior off. ## no-vectorize-slp By default, `rustc` will attempt to vectorize loops using [superword-level -parallism](https://llvm.org/docs/Vectorizers.html#the-slp-vectorizer). This +parallelism](https://llvm.org/docs/Vectorizers.html#the-slp-vectorizer). This flag will turn that behavior off. ## soft-float @@ -206,4 +206,4 @@ This option lets you control what happens when the code panics. ## incremental -This flag allows you to enable incremental compilation. \ No newline at end of file +This flag allows you to enable incremental compilation. diff --git a/src/doc/rustc/src/lints/levels.md b/src/doc/rustc/src/lints/levels.md index 83b65cd648e..19bb6707d22 100644 --- a/src/doc/rustc/src/lints/levels.md +++ b/src/doc/rustc/src/lints/levels.md @@ -45,8 +45,8 @@ pub fn foo() { This will produce this warning: -```bash -> rustc lib.rs --crate-type=lib +```console +$ rustc lib.rs --crate-type=lib warning: unused variable: `x` --> lib.rs:2:9 | diff --git a/src/doc/rustc/src/lints/listing/deny-by-default.md b/src/doc/rustc/src/lints/listing/deny-by-default.md index 0c49f2f7b36..e7ec6af8be1 100644 --- a/src/doc/rustc/src/lints/listing/deny-by-default.md +++ b/src/doc/rustc/src/lints/listing/deny-by-default.md @@ -165,7 +165,7 @@ error: mutating transmuted &mut T from &T may cause undefined behavior, consider This lint detects any `const` items with the `#[no_mangle]` attribute. Constants do not have their symbols exported, and therefore, this probably -means you meant to use a `static`, not a `const. Some example code that +means you meant to use a `static`, not a `const`. Some example code that triggers this lint: ```rust,ignore diff --git a/src/doc/rustc/src/targets/index.md b/src/doc/rustc/src/targets/index.md index cea7ce4dea5..07e3a79471f 100644 --- a/src/doc/rustc/src/targets/index.md +++ b/src/doc/rustc/src/targets/index.md @@ -3,12 +3,11 @@ `rustc` is a cross-compiler by default. This means that you can use any compiler to build for any architecture. The list of *targets* are the possible architectures that you can build for. -You can see the API docs for a given target -[here](https://doc.rust-lang.org/nightly/nightly-rustc/rustc_back/target/struct.Target.html), all -of these options can be set on a per-target basis. +To see all the options that you can set with a target, see the docs +[here](https://doc.rust-lang.org/nightly/nightly-rustc/rustc_back/target/struct.Target.html). To compile to a particular target, use the `--target` flag: ```bash $ rustc src/main.rs --target=wasm32-unknown-unknown -``` \ No newline at end of file +``` -- 2.44.0