@star fucking love writing state machines in rust it's so nice with state = match (character, state) { ... }
exhaustiveness checking to make sure you mentioned every single possible combination of (character, state) and defined what state it transitions(lol) into :)