Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rollup of 7 pull requests #63228

Merged
merged 24 commits into from
Aug 3, 2019
Merged

Rollup of 7 pull requests #63228

merged 24 commits into from
Aug 3, 2019

Conversation

Centril
Copy link
Contributor

@Centril Centril commented Aug 2, 2019

Successful merges:

Failed merges:

r? @ghost

estebank and others added 24 commits July 29, 2019 18:19
When positional width and precision formatting flags are present in a
formatting string that has an argument count mismatch, provide extra
information pointing at them making it easiser to understand where the
problem may lay:

```
error: 4 positional arguments in format string, but there are 3 arguments
  --> $DIR/ifmt-bad-arg.rs:78:15
   |
LL |     println!("{} {:.*} {}", 1, 3.2, 4);
   |               ^^ ^^--^ ^^      --- this parameter corresponds to the precision flag
   |                    |
   |                    this precision flag adds an extra required argument at position 1, which is why there are 4 arguments expected
   |
   = note: positional arguments are zero-based
   = note: for information about formatting flags, visit https://doc.rust-lang.org/std/fmt/index.html

error: 4 positional arguments in format string, but there are 3 arguments
  --> $DIR/ifmt-bad-arg.rs:81:15
   |
LL |     println!("{} {:07$.*} {}", 1, 3.2, 4);
   |               ^^ ^^-----^ ^^      --- this parameter corresponds to the precision flag
   |                    |  |
   |                    |  this precision flag adds an extra required argument at position 1, which is why there are 4 arguments expected
   |                    this width flag expects an `usize` argument at position 7, but there are 3 arguments
   |
   = note: positional arguments are zero-based
   = note: for information about formatting flags, visit https://doc.rust-lang.org/std/fmt/index.html

error: 3 positional arguments in format string, but there are 3 arguments
  --> $DIR/ifmt-bad-arg.rs:84:15
   |
LL |     println!("{} {:07$} {}", 1, 3.2, 4);
   |               ^^ ^^---^ ^^
   |                    |
   |                    this width flag expects an `usize` argument at position 7, but there are 3 arguments
   |
   = note: positional arguments are zero-based
   = note: for information about formatting flags, visit https://doc.rust-lang.org/std/fmt/index.html
```
I had one job...
…-musleabi.

Support for the targets in the compiler and std build in the CI.
Added support for armv7-unknown-linux-gnueabi/musleabi

Fixes rust-lang#63101

Some things that are not done and I hope someone can help me with:

* During the ci build of `armv7-unknown-linux-gnueabi` `openssl` must be built (to build cargo) but `openssl` does not yet support this target. This feels slightly like a chicken-and-egg problem, any feedback is welcome.
* Should I add any tests for any of these targets?
…hton

On `format!()` arg count mismatch provide extra info

When positional width and precision formatting flags are present in a
formatting string that has an argument count mismatch, provide extra
information pointing at them making it easiser to understand where the
problem may lay:

```
error: 4 positional arguments in format string, but there are 3 arguments
  --> $DIR/ifmt-bad-arg.rs:78:15
   |
LL |     println!("{} {:.*} {}", 1, 3.2, 4);
   |               ^^ ^^--^ ^^      --- this parameter corresponds to the precision flag
   |                    |
   |                    this precision flag adds an extra required argument at position 1, which is why there are 4 arguments expected
   |
   = note: positional arguments are zero-based
   = note: for information about formatting flags, visit https://doc.rust-lang.org/std/fmt/index.html

error: 4 positional arguments in format string, but there are 3 arguments
  --> $DIR/ifmt-bad-arg.rs:81:15
   |
LL |     println!("{} {:07$.*} {}", 1, 3.2, 4);
   |               ^^ ^^-----^ ^^      --- this parameter corresponds to the precision flag
   |                    |  |
   |                    |  this precision flag adds an extra required argument at position 1, which is why there are 4 arguments expected
   |                    this width flag expects an `usize` argument at position 7, but there are 3 arguments
   |
   = note: positional arguments are zero-based
   = note: for information about formatting flags, visit https://doc.rust-lang.org/std/fmt/index.html

error: invalid reference to positional argument 7 (there are 3 arguments)
  --> $DIR/ifmt-bad-arg.rs:84:18
   |
LL |     println!("{} {:07$} {}", 1, 3.2, 4);
   |                  ^^^--^
   |                     |
   |                     this width flag expects an `usize` argument at position 7, but there are 3 arguments
   |
   = note: positional arguments are zero-based
   = note: for information about formatting flags, visit https://doc.rust-lang.org/std/fmt/index.html
```

Fix rust-lang#49384.
build_helper: try less confusing method names

build_helper's `*_silent` methods were likely called that way because they do not print the command being run to stdout. [In the original file this all makes sense](rust-lang@046e687#diff-5c3d6537a43ecae03014e118a7fe3321). But later it also gained `*_suppressed` methods and the difference between `silent` and `suppressed` is far from clear.

So rename `run` (which prints the command being run) to `run_verbose`. Then we can call the methods that just run a command and show its output but nothing extra `run` and `try_run`.

`run_verbose` (formerly `run`) is unused from what I can tell. Should I remove it?

r? @alexcrichton
Cc @Mark-Simulacrum
Also see rust-lang#63089 (comment).
Round generator sizes to a multiple of their alignment

Fixes rust-lang#62658.

r? @cramertj
cc @eddyb
Clarify semantics of mem::zeroed

Clarifies the semantics of `mem::zeroed`.

r? @Centril

cc @RalfJung
@Centril
Copy link
Contributor Author

Centril commented Aug 2, 2019

@bors r+ p=7 rollup=never

@bors
Copy link
Contributor

bors commented Aug 2, 2019

📌 Commit 4520a39 has been approved by Centril

@bors bors added the S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. label Aug 2, 2019
@bors
Copy link
Contributor

bors commented Aug 2, 2019

⌛ Testing commit 4520a39 with merge d9bd4b2...

bors added a commit that referenced this pull request Aug 2, 2019
Rollup of 7 pull requests

Successful merges:

 - #63107 (Added support for armv7-unknown-linux-gnueabi/musleabi)
 - #63121 (On `format!()` arg count mismatch provide extra info)
 - #63196 (build_helper: try less confusing method names)
 - #63206 (remove unsupported test case)
 - #63208 (Round generator sizes to a multiple of their alignment)
 - #63212 (Pretty print attributes in `print_arg`)
 - #63215 (Clarify semantics of mem::zeroed)

Failed merges:

r? @ghost
@bors
Copy link
Contributor

bors commented Aug 3, 2019

☀️ Test successful - checks-azure
Approved by: Centril
Pushing d9bd4b2 to master...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label Aug 3, 2019
@bors bors merged commit 4520a39 into rust-lang:master Aug 3, 2019
@rust-highfive
Copy link
Collaborator

📣 Toolstate changed by #63228!

Tested on commit d9bd4b2.
Direct link to PR: #63228

💔 clippy-driver on windows: test-pass → build-fail (cc @Manishearth @llogiq @mcarton @oli-obk @phansch, @rust-lang/infra).
💔 clippy-driver on linux: test-pass → build-fail (cc @Manishearth @llogiq @mcarton @oli-obk @phansch, @rust-lang/infra).

rust-highfive added a commit to rust-lang-nursery/rust-toolstate that referenced this pull request Aug 3, 2019
Tested on commit rust-lang/rust@d9bd4b2.
Direct link to PR: <rust-lang/rust#63228>

💔 clippy-driver on windows: test-pass → build-fail (cc @Manishearth @llogiq @mcarton @oli-obk @phansch, @rust-lang/infra).
💔 clippy-driver on linux: test-pass → build-fail (cc @Manishearth @llogiq @mcarton @oli-obk @phansch, @rust-lang/infra).
@Centril Centril deleted the rollup-x39p5ga branch August 3, 2019 07:25
bors added a commit that referenced this pull request Aug 7, 2019
submodules: Update clippy

r? @Manishearth
Fixes clippy toolstate in #63228 (comment)
@Centril Centril added the rollup A PR which is a rollup label Oct 2, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
merged-by-bors This PR was explicitly merged by bors. rollup A PR which is a rollup S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

9 participants