Skip to content

Commit b7e6532

Browse files
committed
changing the precedence of the semicolon w.r.t else to make it more conventional
1 parent 78ac672 commit b7e6532

File tree

3 files changed

+4
-1
lines changed

3 files changed

+4
-1
lines changed

compiler/src/Parser.y

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,8 +104,8 @@ import Control.Monad.Except
104104
%nonassoc with
105105
%right '=>'
106106
%right '|'
107-
%right ';'
108107
%right else
108+
%right ';'
109109
%left andalso orelse
110110
%nonassoc '=' '<=' '>=' '<>' '<' '>' '@'
111111
%left andb orb xorb

tests/rt/pos/core/gettypebool.golden

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
2024-04-15T10:41:56.876Z [RTM] info: Skipping network creation. Observe that all external IO operations will yield a runtime error.
2+
>>> Main thread finished with value: "boolean"@{}%{}

tests/rt/pos/core/gettypebool.trp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
let val x = true in getType x end

0 commit comments

Comments
 (0)