|
|
@ -256,7 +256,6 @@ impl Rectangle {
|
|
|
|
|
|
|
|
|
|
|
|
```rust
|
|
|
|
```rust
|
|
|
|
#![allow(unused)]
|
|
|
|
#![allow(unused)]
|
|
|
|
fn main() {
|
|
|
|
|
|
|
|
enum Message {
|
|
|
|
enum Message {
|
|
|
|
Quit,
|
|
|
|
Quit,
|
|
|
|
Move { x: i32, y: i32 },
|
|
|
|
Move { x: i32, y: i32 },
|
|
|
@ -270,8 +269,9 @@ impl Message {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
let m = Message::Write(String::from("hello"));
|
|
|
|
fn main() {
|
|
|
|
m.call();
|
|
|
|
let m = Message::Write(String::from("hello"));
|
|
|
|
|
|
|
|
m.call();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
```
|
|
|
|
```
|
|
|
|
|
|
|
|
|
|
|
|