Skip to content

librustc: Take the parameter space into account when combining type #15356

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

Merged
merged 1 commit into from
Jul 4, 2014

Conversation

pcwalton
Copy link
Contributor

@pcwalton pcwalton commented Jul 2, 2014

parameters.

This can break code that mistakenly used type parameters in place of
Self. For example, this will break:

trait Foo {
    fn bar<X>(u: X) -> Self {
        u
    }
}

Change this code to not contain a type error. For example:

trait Foo {
    fn bar<X>(_: X) -> Self {
        self
    }
}

Closes #15172.

[breaking-change]

r? @alexcrichton

parameters.

This can break code that mistakenly used type parameters in place of
`Self`. For example, this will break:

    trait Foo {
        fn bar<X>(u: X) -> Self {
            u
        }
    }

Change this code to not contain a type error. For example:

    trait Foo {
        fn bar<X>(_: X) -> Self {
            self
        }
    }

Closes rust-lang#15172.

[breaking-change]
bors added a commit that referenced this pull request Jul 4, 2014
parameters.

This can break code that mistakenly used type parameters in place of
`Self`. For example, this will break:

    trait Foo {
        fn bar<X>(u: X) -> Self {
            u
        }
    }

Change this code to not contain a type error. For example:

    trait Foo {
        fn bar<X>(_: X) -> Self {
            self
        }
    }

Closes #15172.

[breaking-change]

r? @alexcrichton
@bors bors closed this Jul 4, 2014
@bors bors merged commit c3ae64a into rust-lang:master Jul 4, 2014
bors added a commit to rust-lang-ci/rust that referenced this pull request Aug 7, 2023
fix: Fix bad unwrap in eager_macro_recur

Some logic changed so this path can be hit now with a missing token tree.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Can use + operator in broken and hilarious ways
3 participants