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 10 pull requests #121886

Closed
wants to merge 27 commits into from

Conversation

matthiaskrgr
Copy link
Member

Successful merges:

r? @ghost
@rustbot modify labels: rollup

Create a similar rollup

squell and others added 27 commits March 17, 2023 14:33
When reading through this, I got slightly hung up thinking the `let` it was referring to was the `let tmp` on line 25, which was confusing considering the comment states that the temporary is freed at the end of the block. I think adding this clarification could potentially help some beginners like myself without being overly verbose.
Co-authored-by: Jieyou Xu <jieyouxu@outlook.com>
To the module where it is used, so it doesn't have to be `pub`.
This just moves the server-relevant parts of handles into `server.rs`.
It introduces a new higher-order macro `with_api_handle_types` to avoid
some duplication.

This fixes two `FIXME` comments, and makes things clearer, by not having
server code in `client.rs`.
Clearer wording
fix typo in documentation for std::fs::Permissions

Please check and re-check this PR carefully to see if I got this right.

But by my logic, if the `read_only` function returns `true`, I would not expect be able to write to the file (it being read only); so this text is meant to clarify that `read_only` being `false` doesn't mean *you* can actually write to the file, just that "in general" someone is able to.
Update E0716.md for clarity

When reading through this, I got slightly hung up thinking the `let` it was referring to was the `let tmp` on line 25, which was confusing considering the comment states that the temporary is freed at the end of the block. I think adding this clarification could potentially help some beginners like myself without being overly verbose.
Display short types for unimplemented trait

Shortens unimplemented trait diagnostics. Now shows:

```
error[E0277]: `Option<Option<Option<...>>>` doesn't implement `std::fmt::Display`
  --> $DIR/on_unimplemented_long_types.rs:4:17
   |
LL |   pub fn foo() -> impl std::fmt::Display {
   |                   ^^^^^^^^^^^^^^^^^^^^^^ `Option<Option<Option<...>>>` cannot be formatted with the default formatter
LL |
LL | /     Some(Some(Some(Some(Some(Some(Some(Some(Some(S...
LL | |         Some(Some(Some(Some(Some(Some(Some(Some(So...
LL | |             Some(Some(Some(Some(Some(Some(Some(Som...
LL | |                 Some(Some(Some(Some(Some(Some(Some...
...  |
LL | |         ))))))))))),
LL | |     )))))))))))
   | |_______________- return type was inferred to be `Option<Option<Option<...>>>` here
   |
   = help: the trait `std::fmt::Display` is not implemented for `Option<Option<Option<...>>>`
   = note: in format strings you may be able to use `{:?}` (or {:#?} for pretty-print) instead

error: aborting due to 1 previous error

For more information about this error, try `rustc --explain E0277`.
```

I'm not 100% sure if this is desirable, or if we should just let the long types remain long. This is also kinda a short-term bandaid solution. The real long term solution is to properly migrate `rustc_trait_selection`'s error reporting to use translatable diagnostics and then properly handle type name printing.

Fixes rust-lang#121687.
…henkov

Don't lint on executable crates with `non_snake_case` names

Revives rust-lang#111130, cc `@GilShoshan94.`
Closes rust-lang#45127.
…risDenton

Move thread local implementation to `sys`

Part of rust-lang#117276.
…est31

Move `gather_comments`.

To the module where it is used, so it doesn't have to be `pub`.

r? `@est31`
Move `HandleStore` into `server.rs`.

This just moves the server-relevant parts of handles into `server.rs`. It introduces a new higher-order macro `with_api_handle_types` to avoid some duplication.

This fixes two `FIXME` comments, and makes things clearer, by not having server code in `client.rs`.

r? `@bjorn3`
…les, r=workingjubilee

Use the guaranteed precision of a couple of float functions in docs
…r-errors

 Account for unmet T: !Copy in E0277 message

```
error[E0277]: the trait bound `T: !Copy` is not satisfied
  --> $DIR/simple.rs:10:16
   |
LL |     not_copy::<T>();
   |                ^ the trait bound `T: !Copy` is not satisfied
```
instead of the current

```
error[E0277]: the trait bound `T: !Copy` is not satisfied
  --> $DIR/simple.rs:10:16
   |
LL |     not_copy::<T>();
   |                ^ the trait `!Copy` is not implemented for `T`
```
@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. 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. labels Mar 2, 2024
@rustbot rustbot added the rollup A PR which is a rollup label Mar 2, 2024
@matthiaskrgr
Copy link
Member Author

@bors r+ rollup=never p=10

@bors
Copy link
Contributor

bors commented Mar 2, 2024

📌 Commit a869b6a has been approved by matthiaskrgr

It is now in the queue for this repository.

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Mar 2, 2024
@bors
Copy link
Contributor

bors commented Mar 2, 2024

⌛ Testing commit a869b6a with merge 9be716e...

bors added a commit to rust-lang-ci/rust that referenced this pull request Mar 2, 2024
…iaskrgr

Rollup of 10 pull requests

Successful merges:

 - rust-lang#109263 (fix typo in documentation for std::fs::Permissions)
 - rust-lang#120684 (Update E0716.md for clarity)
 - rust-lang#121739 (Display short types for unimplemented trait)
 - rust-lang#121749 (Don't lint on executable crates with `non_snake_case` names)
 - rust-lang#121758 (Move thread local implementation to `sys`)
 - rust-lang#121815 (Move `gather_comments`.)
 - rust-lang#121835 (Move `HandleStore` into `server.rs`.)
 - rust-lang#121847 (Remove hidden use of Global)
 - rust-lang#121861 (Use the guaranteed precision of a couple of float functions in docs)
 - rust-lang#121875 ( Account for unmet T: !Copy in E0277 message)

r? `@ghost`
`@rustbot` modify labels: rollup
@rust-log-analyzer
Copy link
Collaborator

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

Click to see the possible cause of the failure (guessed by this bot)

@bors
Copy link
Contributor

bors commented Mar 2, 2024

💔 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 Mar 2, 2024
@matthiaskrgr matthiaskrgr deleted the rollup-z9t269j branch March 16, 2024 18:20
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. 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.
Projects
None yet
Development

Successfully merging this pull request may close these issues.