Skip to content

Conversation

@AprilNEA
Copy link
Contributor

@AprilNEA AprilNEA commented Dec 29, 2025

Part of #116971.

Add FileCheck annotations to tests/mir-opt/retag.rs, removing the // skip-filecheck directive.

The added CHECK directives verify that the AddRetag pass correctly inserts Retag statements:

  • At function entry for self and reference parameters (Retag([fn entry] _1), Retag([fn entry] _2))
  • Uses CHECK-NEXT to verify Retag statements appear immediately after bb0: {
  • After reborrows for shared reference return values (Retag(_0))
  • For closures (main::{closure#0}) with proper entry retags
  • For array_casts function (testing retags through &raw)
  • For box_to_raw_mut function with [raw] retag (Retag([raw] _0))

r? @cjgillot

@rustbot rustbot added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels Dec 29, 2025
- Add CHECK for closure (main::{closure#0})
- Use CHECK-NEXT to verify Retag statements order after bb0
- Verify Retag for both self (_1) and reference parameters (_2)
@AprilNEA AprilNEA marked this pull request as ready for review December 29, 2025 09:31
@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Dec 29, 2025
@rustbot
Copy link
Collaborator

rustbot commented Dec 29, 2025

⚠️ Warning ⚠️

  • There are issue links (such as #123) in the commit messages of the following commits.
    Please move them to the PR description, to avoid spamming the issues with references to the commit, and so this bot can automatically canonicalize them to avoid issues with subtree.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

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.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants