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

Improve spans with use crate::{self} #104315

Merged
merged 1 commit into from
Nov 13, 2022
Merged

Conversation

SparkyPotato
Copy link
Contributor

Fixes #104276.

The error becomes:

error: crate root imports need to be explicitly named: `use crate as name;`
 --> src/lib.rs.rs:1:13
  |
1 | use crate::{self};
  |             ^^^^

warning: unused import: `self`
 --> src/lib.rs:1:13
  |
1 | use crate::{self};
  |             ^^^^
  |
  = note: `#[warn(unused_imports)]` on by default

@rustbot
Copy link
Collaborator

rustbot commented Nov 12, 2022

r? @estebank

(rustbot has picked a reviewer for you, use r? to override)

@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. labels Nov 12, 2022
@cjgillot
Copy link
Contributor

@SparkyPotato could you add a ui test for this?

@SparkyPotato
Copy link
Contributor Author

Done!

@cjgillot
Copy link
Contributor

@bors r+

@bors
Copy link
Contributor

bors commented Nov 13, 2022

📌 Commit c7b2891 has been approved by cjgillot

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 Nov 13, 2022
bors added a commit to rust-lang-ci/rust that referenced this pull request Nov 13, 2022
…iaskrgr

Rollup of 5 pull requests

Successful merges:

 - rust-lang#103996 (Add small clarification around using pointers derived from references)
 - rust-lang#104315 (Improve spans with `use crate::{self}`)
 - rust-lang#104320 (Use `derive_const` and rm manual StructuralEq impl)
 - rust-lang#104357 (add is_sized method on Abi and Layout, and use it)
 - rust-lang#104365 (Add x tool to triagebot)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit 5c764da into rust-lang:master Nov 13, 2022
@rustbot rustbot added this to the 1.67.0 milestone Nov 13, 2022
Aaron1011 pushed a commit to Aaron1011/rust that referenced this pull request Jan 6, 2023
…iaskrgr

Rollup of 5 pull requests

Successful merges:

 - rust-lang#103996 (Add small clarification around using pointers derived from references)
 - rust-lang#104315 (Improve spans with `use crate::{self}`)
 - rust-lang#104320 (Use `derive_const` and rm manual StructuralEq impl)
 - rust-lang#104357 (add is_sized method on Abi and Layout, and use it)
 - rust-lang#104365 (Add x tool to triagebot)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
@SparkyPotato SparkyPotato deleted the fix-104276 branch May 29, 2023 19:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
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.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Cryptic error on crate root import
6 participants