diff --git a/Parser.cs b/Parser.cs index 9db5c7b..e0efae7 100644 --- a/Parser.cs +++ b/Parser.cs @@ -142,7 +142,9 @@ class Parser private Expr sum() => binaryLeft(product, TokenType.Minus, TokenType.Plus); - private Expr product() => binaryLeft(unary, TokenType.Slash, TokenType.Asterisk); + private Expr product() => binaryLeft(concat, TokenType.Slash, TokenType.Asterisk); + + private Expr concat() => binaryLeft(unary, TokenType.PlusPlus); private Expr unary() {