Skip to content

Regression with type parameter shadowing #32639

Closed
@alexcrichton

Description

@alexcrichton
Member

The following code compiles on stable/beta but fails to compile on nightly

pub enum T {       
    NonSpecific,   
}                  

fn foo<T>() {      
    T::NonSpecific;
}                  

This is minimized from a regression in the quire crate. This looks pretty intentional, however, so I just wanted to confirm! Was this intentional, and are we comfortable letting this slide through?

cc @jseyfried

Activity

added
T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.
on Mar 31, 2016
jseyfried

jseyfried commented on Mar 31, 2016

@jseyfried
Contributor

Yeah, this was intentional -- it was changed in #32141 to fix #32120.
Could there be more breakage (i.e. was this not detected in a crater run)?

alexcrichton

alexcrichton commented on Mar 31, 2016

@alexcrichton
MemberAuthor

This may be all the breakage we're looking at, that was just a crater run between stable and nightly last night, and it was the only error its kind that showed up.

jseyfried

jseyfried commented on Mar 31, 2016

@jseyfried
Contributor

Ok, I'll write a PR to fix the breakage in that crate. I could also do a warning cycle pretty easily but it looks like that won't be needed.

pnkfelix

pnkfelix commented on Mar 31, 2016

@pnkfelix
Member

(Yes this is expected to break due to aforementioned fix.)

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.regression-from-stable-to-nightlyPerformance or correctness regression from stable to nightly.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

      Development

      No branches or pull requests

        Participants

        @alexcrichton@pnkfelix@jseyfried

        Issue actions

          Regression with type parameter shadowing · Issue #32639 · rust-lang/rust