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 20:34:04 -07:00
fn child2(&&s: str) { }
2012-01-04 21:14:53 -08:00
fn main() { let x = task::spawn {|| child2("hi"); }; }