2019-07-27 00:54:25 +03:00
|
|
|
// run-pass
|
2010-08-03 12:20:29 -07:00
|
|
|
// Reported as issue #126, child leaks the string.
|
2011-08-13 15:20:11 -07:00
|
|
|
|
2015-03-22 13:13:15 -07:00
|
|
|
// pretty-expanded FIXME #23616
|
2016-02-11 12:34:41 +01:00
|
|
|
// ignore-emscripten no threads support
|
2015-03-22 13:13:15 -07:00
|
|
|
|
2015-03-30 11:00:05 -07:00
|
|
|
use std::thread;
|
2011-08-13 15:20:11 -07:00
|
|
|
|
2014-05-22 16:57:53 -07:00
|
|
|
fn child2(_s: String) { }
|
2010-08-03 12:20:29 -07:00
|
|
|
|
2013-05-07 21:33:31 -07:00
|
|
|
pub fn main() {
|
2015-03-30 11:00:05 -07:00
|
|
|
let _x = thread::spawn(move|| child2("hi".to_string()));
|
2013-05-07 21:33:31 -07:00
|
|
|
}
|