Skip to content

Conversation

celinval
Copy link
Contributor

@celinval celinval commented Nov 23, 2023

In stable mir, we specialize DefId, however some functionality is the same for every definition, such as def paths, and getting their crate. Use a trait to implement those.

This will allow users to use rustc span messages to display user
friendly messages.
@rustbot
Copy link
Collaborator

rustbot commented Nov 23, 2023

r? @spastorino

(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 23, 2023
@rustbot
Copy link
Collaborator

rustbot commented Nov 23, 2023

This PR changes Stable MIR

cc @oli-obk, @celinval, @spastorino, @ouz-a

@rust-log-analyzer

This comment has been minimized.

Copy link
Contributor

@ouz-a ouz-a left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

few nits, this is very nice change thanks!

@ouz-a ouz-a self-assigned this Nov 24, 2023
@ouz-a
Copy link
Contributor

ouz-a commented Nov 24, 2023

@bors r+ rollup

@bors
Copy link
Collaborator

bors commented Nov 24, 2023

📌 Commit b6e9772 has been approved by ouz-a

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 24, 2023
bors added a commit to rust-lang-ci/rust that referenced this pull request Nov 24, 2023
…mpiler-errors

Rollup of 7 pull requests

Successful merges:

 - rust-lang#118187 (Recompile LLVM when it changes in the git sources)
 - rust-lang#118210 (intercrate ambiguity causes: ignore candidates which don't apply)
 - rust-lang#118215 (Add common trait for crate definitions)
 - rust-lang#118238 (memcpy assumptions: update GCC link)
 - rust-lang#118243 (EvalCtxt::commit_if_ok don't inherit nested goals)
 - rust-lang#118245 (Add `Span` to `TraitBoundModifier`)
 - rust-lang#118246 (Remove a hack for effects)

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit 8294352 into rust-lang:master Nov 24, 2023
@rustbot rustbot added this to the 1.76.0 milestone Nov 24, 2023
rust-timer added a commit to rust-lang-ci/rust that referenced this pull request Nov 24, 2023
Rollup merge of rust-lang#118215 - celinval:smir-def-paths, r=ouz-a

Add common trait for crate definitions

In stable mir, we specialize DefId, however some functionality is the same for every definition, such as def paths, and getting their crate. Use a trait to implement those.
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.

7 participants