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 #89763

Closed
wants to merge 19 commits into from

Conversation

matthiaskrgr
Copy link
Member

Successful merges:

Failed merges:

r? @ghost
@rustbot modify labels: rollup

Create a similar rollup

a1phyr and others added 19 commits October 4, 2021 13:26
Shallow clones can cause `git rev-list --merges` to miss merge
commits. Omit it, because the most recent bors commit is
almost always a merge commit.
Exit with an error if we can't find a commit hash for downloading
LLVM or rustc snapshots.
Rustc was incorrectly reading the value of `RUSTC_LOG` as the
environment vairable with the logging configuration, rather than the
logging configuration itself.
…htriplett

Add vectored positioned I/O on Unix

Add methods for vectored I/O with an offset on `File` for `unix` under `#![feature(unix_file_vectored_at)]`.

The new methods are wrappers around `preadv` and `pwritev`.

Tracking issue: rust-lang#89517
bootstrap: don't use `--merges` to look for commit hashes for downloading artifacts

Shallow clones (and possibly worktrees, though I can't seem to reproduce the problem there) can cause `git rev-list --merges` to falsely return no results, even if a merge commit is present. Stop using the `--merges` option when looking for commit hashes that have build artifacts. `--first-parent` and `--author=bors@rust-lang.org` should be sufficient.

Also exit with an error if the configuration asks for artifacts to be downloaded and we can't determine an appropriate commit hash to use to download artifacts.

Fixes rust-lang#87890.

r? `@jyn514`
`@rustbot` label +A-rustbuild +A-contributor-roadblock
…rs, r=joshtriplett

Add #[must_use] to alloc constructors

Added `#[must_use]`. to the various forms of `new`, `pin`, and `with_capacity` in the `alloc` crate. No extra explanations given as I couldn't think of anything useful to add.

I figure this deserves extra scrutiny compared to the other PRs I've done so far. In particular:

* The 4 `pin`/`pin_in` methods I touched. Are there legitimate use cases for pinning and not using the result? Pinning's a difficult concept I'm not very comfortable with.
* `Box`'s constructors. Do people ever create boxes just for the side effects... allocating or zeroing out memory?

Parent issue: rust-lang#89692

r? `@joshtriplett`
…ctors, r=joshtriplett

Add #[must_use] to core and std constructors

Parent issue: rust-lang#89692

r? `@joshtriplett`
Fix RUSTC_LOG handling

Rustc was incorrectly reading the value of `RUSTC_LOG` as the environment vairable with the logging configuration, rather than the logging configuration itself.
…rsions, r=joshtriplett

Add #[must_use] to from_value conversions

I added two methods to the list myself. Clippy did not flag them because they take `mut` args, but neither modifies their argument.

```rust
core::str           const unsafe fn from_utf8_unchecked_mut(v: &mut [u8]) -> &mut str;
std::ffi::CString   unsafe fn from_raw(ptr: *mut c_char) -> CString;
```

I put a custom note on `from_raw`:

```rust
#[must_use = "call `drop(from_raw(ptr))` if you intend to drop the `CString`"]
pub unsafe fn from_raw(ptr: *mut c_char) -> CString {
```

Parent issue: rust-lang#89692

r? `@joshtriplett`
…=lnicola

⬆️ rust-analyzer

r? `@ghost`
@rustbot rustbot added the rollup A PR which is a rollup label Oct 11, 2021
@matthiaskrgr
Copy link
Member Author

@bors r+ p=7

@bors
Copy link
Contributor

bors commented Oct 11, 2021

📌 Commit 726e477 has been approved by matthiaskrgr

@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 Oct 11, 2021
@bors
Copy link
Contributor

bors commented Oct 11, 2021

⌛ Testing commit 726e477 with merge 719050202d239de811778b00a0397cd74e66123c...

@rust-log-analyzer
Copy link
Collaborator

The job dist-various-2 failed! Check out the build log: (web) (plain)

Click to see the possible cause of the failure (guessed by this bot)
[RUSTC-TIMING] core test:false 15.649
[RUSTC-TIMING] addr2line test:false 0.427
[RUSTC-TIMING] gimli test:false 4.080
[RUSTC-TIMING] object test:false 4.120
error[E0425]: cannot find function `preadv` in crate `libc`
   --> library/std/src/sys/unix/fd.rs:133:19
133 |             libc::preadv(
    |                   ^^^^^^ help: a function with a similar name exists: `pread`
    |
   ::: /cargo/registry/src/github.com-1ecc6299db9ec823/libc-0.2.103/src/unix/mod.rs:933:5
   ::: /cargo/registry/src/github.com-1ecc6299db9ec823/libc-0.2.103/src/unix/mod.rs:933:5
    |
933 |     pub fn pread(fd: ::c_int, buf: *mut ::c_void, count: ::size_t, offset: off_t) -> ::ssize_t;
    |     ------------------------------------------------------------------------------------------- similarly named function `pread` defined here

error[E0425]: cannot find function `pwritev` in crate `libc`
   --> library/std/src/sys/unix/fd.rs:213:19
    |
213 |             libc::pwritev(
    |                   ^^^^^^^ help: a function with a similar name exists: `pwrite`
   ::: /cargo/registry/src/github.com-1ecc6299db9ec823/libc-0.2.103/src/unix/mod.rs:938:5
    |
    |
938 |     pub fn pwrite(fd: ::c_int, buf: *const ::c_void, count: ::size_t, offset: off_t) -> ::ssize_t;
    |     ---------------------------------------------------------------------------------------------- similarly named function `pwrite` defined here
For more information about this error, try `rustc --explain E0425`.
[RUSTC-TIMING] std test:false 1.946
error: could not compile `std` due to 2 previous errors
Build completed unsuccessfully in 0:15:29

@bors
Copy link
Contributor

bors commented Oct 11, 2021

💔 Test failed - checks-actions

@bors bors added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Oct 11, 2021
@matthiaskrgr matthiaskrgr deleted the rollup-q4g2wt4 branch November 20, 2021 15:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
rollup A PR which is a rollup S-waiting-on-review Status: Awaiting review from the assignee but also interested parties.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

9 participants