diff options
Diffstat (limited to 'src/term.rs')
| -rw-r--r-- | src/term.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/term.rs b/src/term.rs index 20098a0..2303fa2 100644 --- a/src/term.rs +++ b/src/term.rs @@ -67,7 +67,7 @@ pub enum Key { Down, Left, Right, - Char(char), + Char(u8), } pub fn read_key(stdin: &mut Stdin) -> Result<Key, String> { @@ -83,7 +83,7 @@ pub fn read_key(stdin: &mut Stdin) -> Result<Key, String> { return Ok(Key::CtrlQ); } if buf[0] != ESC { - return Ok(Key::Char(char::from(buf[0]))); + return Ok(Key::Char(buf[0])); } // Try to handle an escape sequence. let mut buf = vec![0; 2]; |
