Skip to content

Commit b2526f5

Browse files
Fix inliner for integer bitwise operators
1 parent fe6a709 commit b2526f5

File tree

2 files changed

+9
-9
lines changed

2 files changed

+9
-9
lines changed

src/Language/PureScript/CodeGen/JS/Optimizer/Inliner.hs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -150,9 +150,9 @@ inlineCommonOperators = applyAll $
150150
, binary heytingAlgebraBoolean opDisj Or
151151
, unary heytingAlgebraBoolean opNot Not
152152

153-
, binary' C.dataIntBits (C..|.) BitwiseOr
154-
, binary' C.dataIntBits (C..&.) BitwiseAnd
155-
, binary' C.dataIntBits (C..^.) BitwiseXor
153+
, binary' C.dataIntBits C.or BitwiseOr
154+
, binary' C.dataIntBits C.and BitwiseAnd
155+
, binary' C.dataIntBits C.xor BitwiseXor
156156
, binary' C.dataIntBits C.shl ShiftLeft
157157
, binary' C.dataIntBits C.shr ShiftRight
158158
, binary' C.dataIntBits C.zshr ZeroFillShiftRight

src/Language/PureScript/Constants.hs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -118,14 +118,14 @@ disj = "disj"
118118
unsafeIndex :: String
119119
unsafeIndex = "unsafeIndex"
120120

121-
(.|.) :: String
122-
(.|.) = ".|."
121+
or :: String
122+
or = "or"
123123

124-
(.&.) :: String
125-
(.&.) = ".&."
124+
and :: String
125+
and = "and"
126126

127-
(.^.) :: String
128-
(.^.) = ".^."
127+
xor :: String
128+
xor = "xor"
129129

130130
(<<<) :: String
131131
(<<<) = "<<<"

0 commit comments

Comments
 (0)