mirror of
https://github.com/rust-lang/rustlings.git
synced 2026-01-06 10:49:19 +00:00
Add variants to Message enum
This commit is contained in:
parent
73d43b3f90
commit
cac63c180d
@ -3,11 +3,12 @@
|
|||||||
// Execute `rustlings hint enums2` or use the `hint` watch subcommand for a
|
// Execute `rustlings hint enums2` or use the `hint` watch subcommand for a
|
||||||
// hint.
|
// hint.
|
||||||
|
|
||||||
// I AM NOT DONE
|
|
||||||
|
|
||||||
#[derive(Debug)]
|
#[derive(Debug)]
|
||||||
enum Message {
|
enum Message {
|
||||||
// TODO: define the different variants used below
|
Move { x: i32, y: i32 },
|
||||||
|
Echo(String),
|
||||||
|
ChangeColor(u8, u8, u8),
|
||||||
|
Quit,
|
||||||
}
|
}
|
||||||
|
|
||||||
impl Message {
|
impl Message {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user