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

compiletest: run-rustfix and revisions have broken interactions #123596

Closed
jieyouxu opened this issue Apr 7, 2024 · 0 comments · Fixed by #123601
Closed

compiletest: run-rustfix and revisions have broken interactions #123596

jieyouxu opened this issue Apr 7, 2024 · 0 comments · Fixed by #123601
Assignees
Labels
A-testsuite Area: The testsuite used to check the correctness of rustc C-bug Category: This is a bug. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.

Comments

@jieyouxu
Copy link
Member

jieyouxu commented Apr 7, 2024

compiletest currently accepts both run-rustfix and revision directives:

  • //@ run-rustfix, and
  • //@ revisions: r1 ... rn

However, run-rustfix does not correctly account for revisions, because revisions + run-rustfix together tries to create a new crate named after each revision <test-name>.<revisions>, which is not a valid Rust crate name because of the ..

Example UI test where the author had to workaround it by explicitly setting #![crate_name]:

// FIXME: the test suite tries to create a crate called `bare_trait_dont_suggest_dyn.new`

@jieyouxu jieyouxu added A-testsuite Area: The testsuite used to check the correctness of rustc T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. C-bug Category: This is a bug. labels Apr 7, 2024
@rustbot rustbot added the needs-triage This issue may need triage. Remove it if it has been sufficiently triaged. label Apr 7, 2024
@jieyouxu jieyouxu removed the needs-triage This issue may need triage. Remove it if it has been sufficiently triaged. label Apr 7, 2024
@jieyouxu jieyouxu self-assigned this Apr 7, 2024
@bors bors closed this as completed in 9d5cdf7 Apr 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-testsuite Area: The testsuite used to check the correctness of rustc C-bug Category: This is a bug. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants