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

Closed
wants to merge 47 commits into from
Closed

Conversation

Dylan-DPC
Copy link
Member

Successful merges:

Failed merges:

r? @ghost
@rustbot modify labels: rollup

Create a similar rollup

joboet and others added 30 commits September 28, 2022 16:54
Co-authored-by: Nathan Stocks <[email protected]>
Co-authored-by: rdvdev2 <[email protected]>
Add `Noted` marker struct that implements `EmissionGuarantee` so that
`emit_note` and `create_note` can be implemented for struct diagnostics.

Signed-off-by: David Wood <[email protected]>
joboet and others added 17 commits October 8, 2022 09:07
rust-lang#100892 implemented AsFd for the
sys versions, rather than for the public types. Change the
implementations to apply to the public types.
When this was added, the sidebar had a bit more complex style. It can be
removed, now.
…nostics, r=davidtwco

Migrate rustc_passes diagnostics

Picks up abandoned work from rust-lang#100870

I would like to do this collaboratively, as there is a lot of work! Here's the process:

- Comment below that you are willing to help and I will add you as a collaborator to my `rust` fork (that gives you write access)
- Indicate which file/task you would like to work on (so we don't duplicate work) from the list below
- Do the work, push up a commit, comment that you're done with that file/task
- Repeat until done 😄

### Files to Migrate (in `compiler/rustc_passes/src/`)

- [x] check_attr.rs `@CleanCut`
- [x] check_const.rs `@CleanCut`
- [x] dead.rs `@CleanCut`
- [x] debugger_visualizer.rs `@CleanCut`
- [x] diagnostic_items.rs `@CleanCut`
- [x] entry.rs `@CleanCut`
- [x] lang_items.rs `@CleanCut`
- [x] layout_test.rs `@CleanCut`
- [x] lib_features.rs `@CleanCut`
- [x] ~liveness.rs~ `@CleanCut` Nothing to do
- [x] loops.rs `@CleanCut`
- [x] naked_functions.rs `@CleanCut`
- [x] stability.rs `@CleanCut`
- [x] weak_lang_items.rs `@CleanCut`

### Tasks

- [x] Rebase on current `master` `@CleanCut`
- [x] Review work from [the earlier PR](rust-lang#100870) and make sure it all looks good
  - [x] compiler/rustc_error_messages/locales/en-US/passes.ftl `@CleanCut`
  - [x] compiler/rustc_passes/src/check_attr.rs `@CleanCut`
  - [x] compiler/rustc_passes/src/errors.rs `@CleanCut`
  - [x] compiler/rustc_passes/src/lang_items.rs `@CleanCut`
  - [x] compiler/rustc_passes/src/lib.rs `@CleanCut`
  - [x] compiler/rustc_passes/src/weak_lang_items.rs `@CleanCut`
Never panic in `thread::park` and `thread::park_timeout`

fixes rust-lang#102398

``@rustbot`` label +T-libs +T-libs-api
Use semaphores for thread parking on Apple platforms

Currently we use a mutex-condvar pair for thread parking on Apple systems. Unfortunately, `pthread_cond_timedwait` uses the real-time clock for measuring time, which causes problems when the system time changes. The parking implementation in this PR uses a semaphore instead, which measures monotonic time by default, avoiding these issues. As a further benefit, this has the potential to improve performance a bit, since `unpark` does not need to wait for a lock to be released.

Since the Mach semaphores are poorly documented (I could not find availability or stability guarantees for instance), this uses a [dispatch semaphore](https://developer.apple.com/documentation/dispatch/dispatch_semaphore?language=objc) instead. While it adds a layer of indirection (it uses Mach semaphores internally), the overhead is probably negligible.

Tested on macOS 12.5.

r? ``@thomcc``
…-for-io-types, r=m-ou-se

impl AsFd and AsRawFd for io::{Stdin, Stdout, Stderr}, not the sys versions

rust-lang#100892 implemented AsFd for the
sys versions, rather than for the public types. Change the
implementations to apply to the public types.
Move lifetime resolution module to rustc_hir_analysis.

Now that lifetime resolution has been removed from it, this file has nothing to do in `rustc_resolve`.  It's purpose is to compute Debruijn indices for lifetimes, so let's put it in type collection.
… r=GuillaumeGomez

rustdoc: remove unneeded `<div>` wrapper from sidebar DOM

When this was added, the sidebar had a bit more complex style. It can be removed, now.

Preview: https://notriddle.com/notriddle-rustdoc-demos/sidebar-block/std/index.html
@rustbot rustbot added A-translation Area: Translation infrastructure, and migrating existing diagnostics to SessionDiagnostic T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-libs Relevant to the library team, which will review and decide on the PR/issue. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue. rollup A PR which is a rollup labels Oct 11, 2022
@Dylan-DPC
Copy link
Member Author

@bors r+ rollup=never p=5

@bors
Copy link
Contributor

bors commented Oct 11, 2022

📌 Commit f09bc51 has been approved by Dylan-DPC

It is now in the queue for this repository.

@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, 2022
@klensy
Copy link
Contributor

klensy commented Oct 11, 2022

intersects with #102915

@Dylan-DPC
Copy link
Member Author

thanks

@Dylan-DPC Dylan-DPC closed this Oct 11, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-translation Area: Translation infrastructure, and migrating existing diagnostics to SessionDiagnostic 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. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-libs Relevant to the library team, which will review and decide on the PR/issue. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.