File tree Expand file tree Collapse file tree 1 file changed +12
-6
lines changed Expand file tree Collapse file tree 1 file changed +12
-6
lines changed Original file line number Diff line number Diff line change @@ -58,11 +58,16 @@ fn test5(x: &Bar, a: isize) -> isize {
5858 x. extension_method ( a)
5959}
6060
61- #[ rustc_mir]
62- fn test6 < T : Bar > ( x : & T , a : isize ) -> isize {
63- // Test calling extension method on generic callee
64- x. extension_method ( a)
65- }
61+ // FIXME #30661: Although this function has the #[rustc_mir] attribute it never
62+ // was translated via the MIR implementation because attributes
63+ // where not passed along to trans::base::trans_fn() for generic
64+ // functions.
65+ // Uncomment this test once the thing it tests is fixed.
66+ // #[rustc_mir]
67+ // fn test6<T: Bar>(x: &T, a: isize) -> isize {
68+ // // Test calling extension method on generic callee
69+ // x.extension_method(a)
70+ // }
6671
6772trait One < T = Self > {
6873 fn one ( ) -> T ;
@@ -94,7 +99,8 @@ fn main() {
9499 assert_eq ! ( test3( & Foo , 42 ) , 42 ) ;
95100 assert_eq ! ( test4( & Foo , 970 ) , 970 ) ;
96101 assert_eq ! ( test5( & Foo , 8576 ) , 8576 ) ;
97- assert_eq ! ( test6( & Foo , 12367 ) , 12367 ) ;
102+ // see definition of test6() above
103+ // assert_eq!(test6(&Foo, 12367), 12367);
98104 assert_eq ! ( test7( ) , 1 ) ;
99105 assert_eq ! ( test8( ) , 2 ) ;
100106}
You can’t perform that action at this time.
0 commit comments