// compile-flags: -Zverbosefnto_fn_once<F:FnOnce()>(f:F)->F{f}fnf<T:std::fmt::Display>(y:T){structFoo<U:std::fmt::Display>{x:U};letfoo=Foo{x:"x"};letc=to_fn_once(move||{println!("{} {}",foo.x,y);});c();c();//~^ ERROR use of moved value}fnmain(){f("S");}