rust/src/test/run-pass/child-outlives-parent.rs

9 lines
155 B
Rust
Raw Normal View History

// Reported as issue #126, child leaks the string.
use std;
import task;
2011-10-20 22:34:04 -05:00
fn child2(&&s: str) { }
2012-01-04 23:14:53 -06:00
fn main() { let x = task::spawn {|| child2("hi"); }; }