mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-01 15:01:51 +00:00
15 lines
287 B
Rust
15 lines
287 B
Rust
use std::sync::mpsc::channel;
|
|
use std::thread::spawn;
|
|
use std::marker::PhantomData;
|
|
|
|
struct Foo<T> {foo: PhantomData<T>}
|
|
|
|
fn main() {
|
|
let (tx, rx) =
|
|
channel();
|
|
spawn(move || {
|
|
tx.send(Foo{ foo: PhantomData });
|
|
//~^ ERROR type annotations needed
|
|
});
|
|
}
|