Sfoglia il codice sorgente

fixed precedence of ::

Nicolas Cannasse 7 anni fa
parent
commit
67bdb5b762
1 ha cambiato i file con 2 aggiunte e 1 eliminazioni
  1. 2 1
      src/syntax/parser.ml

+ 2 - 1
src/syntax/parser.ml

@@ -136,7 +136,8 @@ let precedence op =
 	| OpIn -> 0, right
 	| OpMod -> 1, left
 	| OpMult | OpDiv -> 2, left
-	| OpAdd | OpSub | OpList -> 3, left
+	| OpAdd | OpSub -> 3, left
+	| OpList -> 3, right
 	| OpShl | OpShr | OpUShr -> 4, left
 	| OpOr | OpAnd | OpXor -> 5, left
 	| OpEq | OpNotEq | OpGt | OpLt | OpGte | OpLte -> 6, left