]> git.lizzy.rs Git - rust.git/commit
Prohibit type parameter shadowing with a clunky hammer.
authorHuon Wilson <dbau.pp+github@gmail.com>
Thu, 8 Jan 2015 00:39:45 +0000 (11:39 +1100)
committerHuon Wilson <dbau.pp+github@gmail.com>
Thu, 8 Jan 2015 01:27:28 +0000 (12:27 +1100)
commit92cd8ea96ad2a1da51863b7f089baec41ed10ce9
tree26c6f3525c1481d5e8cd54c8c2a336ca67a1ba9b
parent9f1ead8fadc56bad30dc74f5cc50d78af4fbc972
Prohibit type parameter shadowing with a clunky hammer.

This is a [breaking-change].

Change

    impl<T> Foo<T> {
        fn bar<T>(...

to (for example)

    impl<T> Foo<T> {
        fn bar<U>(...

Per RFC 459.

Closes #19390.
src/librustc_typeck/check/wf.rs
src/libserialize/json.rs
src/test/compile-fail/shadowed-type-parameter.rs [new file with mode: 0644]