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

Add test for RPIT defined with different hidden types with different substs #111943

Closed
BoxyUwU opened this issue May 25, 2023 · 1 comment · Fixed by #111947
Closed

Add test for RPIT defined with different hidden types with different substs #111943

BoxyUwU opened this issue May 25, 2023 · 1 comment · Fixed by #111947
Assignees
Labels
E-easy Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue. E-needs-test Call for participation: An issue has been fixed and does not reproduce, but no test has been added. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.

Comments

@BoxyUwU
Copy link
Member

BoxyUwU commented May 25, 2023

The following code:

trait Trait {}
impl Trait for () {}

fn foo<T: Trait, U: Trait>() -> impl Trait {
    let a: T = foo::<T, U>();
    loop {}
    let _: T = foo::<U, T>();
}

used to incorrectly compile but now correctly errors, we should add a test to ensure this doesn't regress.

cc #111853 @compiler-errors

@BoxyUwU BoxyUwU added E-easy Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels May 25, 2023
@Noratrieb Noratrieb added the E-needs-test Call for participation: An issue has been fixed and does not reproduce, but no test has been added. label May 25, 2023
@obeis
Copy link
Contributor

obeis commented May 25, 2023

@rustbot claim

compiler-errors added a commit to compiler-errors/rust that referenced this issue May 26, 2023
Add test for RPIT defined with different hidden types with different substs

Close rust-lang#111943
@bors bors closed this as completed in 39b633e May 26, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
E-easy Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue. E-needs-test Call for participation: An issue has been fixed and does not reproduce, but no test has been added. 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.

3 participants