okay that's how

This commit is contained in:
🪞👃🪞 2025-01-12 02:42:13 +01:00
parent 19ed6a24b8
commit 4ab08e48e5
2 changed files with 20 additions and 25 deletions

View file

@ -26,13 +26,11 @@ impl<'a> Token<'a> {
':'|'@' => Sym(source, index, 1),
'0'..='9' => Num(source, index, 1),
'a'..='z' => Key(source, index, 1),
//'\'' => Chr(source, index, 1),
_ => return Err(ParseError::Unexpected(c))
},
Num(_, _, 0) => unreachable!(),
Sym(_, _, 0) => unreachable!(),
Key(_, _, 0) => unreachable!(),
//Chr(_, _, 0) => unreachable!(),
Num(source, index, length) => match c {
'0'..='9' => Num(source, index, length + 1),
' '|'\n'|'\r'|'\t' => return Ok((

View file

@ -1,23 +1,20 @@
(enter note/put)
(del note/del)
(',' note/dur/dec)
('.' note/dur/inc)
('+' note/range/inc)
('-' note/range/dec)
(up note/pos/inc)
(down note/pos/dec)
(left time/pos/dec)
(right time/pos/inc)
('z' time/zoom/lock)
('=' time/zoom/in)
('-' time/zoom/out)
;(@ctrl-k (midi/kbd/toggle))
;(@space (clock/toggle))
;(@shift-space (clock/toggle-start))
;(@u (undo))
;(@shift-u (redo))
;(@tab (compact/toggle))
;(@q (player/enqueue :clip))
;(@0 (player/enqueue :stop)))
(:enter note/put)
(:del note/del)
(:comma note/dur/dec)
(:period note/dur/inc)
(:plus note/range/inc)
(:underscore note/range/dec)
(:up note/pos/inc)
(:down note/pos/dec)
(:left time/pos/dec)
(:right time/pos/inc)
(:z time/zoom/lock)
(:equal time/zoom/in)
(:minus time/zoom/out)
(:space clock/toggle)
(:shift-space clock/toggle/zero)
(:u undo)
(:r redo)
(:tab compact)
(:q enqueue)
(:0 stop)