Crafting Interpreters in Rust: Parsing groups

We’re almost done with expressions. Next we add grouping with parentheses. Recall that primary is defined in the book as follows: primary → NUMBER | STRING | "true" | "false" | "nil" | "(" expression ")" ; We need to implement that "(" expression ")" bit. The test looks like this: #[test] fn grouping_multiply_divide () { let parser = lox :: ExpressionParser :: new (); let expr = parser . parse (…