File tree Expand file tree Collapse file tree 1 file changed +14
-0
lines changed Expand file tree Collapse file tree 1 file changed +14
-0
lines changed Original file line number Diff line number Diff line change 11// run-pass
22
33#![ feature( generators) ]
4+ #![ feature( destructuring_assignment) ]
5+ #![ feature( unboxed_closures, fn_traits) ]
46
57#![ allow( non_camel_case_types) ]
68#![ allow( dead_code) ]
@@ -172,6 +174,17 @@ fn unicode() {
172174 } , '🤔' ) ;
173175}
174176
177+ fn function ( ) {
178+ struct foo ;
179+ impl FnOnce < ( ) > for foo {
180+ type Output = foo ;
181+ extern "rust-call" fn call_once ( self , _args : ( ) ) -> Self :: Output {
182+ foo
183+ }
184+ }
185+ let foo = foo ( ) ( ) ( ) ( ) ( ) ( ) ( ) ( ) ( ) ( ) ( ) ( ) ( ) ( ) ( ) ;
186+ }
187+
175188fn bathroom_stall ( ) {
176189 let mut i = 1 ;
177190 matches ! ( 2 , _|_|_|_|_|_ if ( i+=1 ) != ( i+=1 ) ) ;
@@ -198,5 +211,6 @@ pub fn main() {
198211 match_nested_if ( ) ;
199212 monkey_barrel ( ) ;
200213 unicode ( ) ;
214+ function ( ) ;
201215 bathroom_stall ( ) ;
202216}
You can’t perform that action at this time.
0 commit comments