Commit c1a6873c authored by Bernd Brassel's avatar Bernd Brassel
Browse files

negate float added

parent fc22a5aa
......@@ -683,7 +683,12 @@ negate Zero = Zero
negate (Pos x) = Neg x
negate (Neg x) = Pos x
--- Unary minus on Floats. Usually written as "-e".
negateFloat :: Float -> Float
negateFloat x = prim_negateFloat $# x
prim_negateFloat :: Float -> Float
prim_negateFloat external
-- Constraints
data Success = Success
......
......@@ -1028,6 +1028,9 @@ prim_chr ci _ = toCurry (chr (fromCurry ci))
(===) :: Curry a => a -> a -> Result C_Bool --C_Success
(===) = genStrEq
prim_negateFloat :: C_Float -> Result C_Float
prim_negateFloat x _ = negate x
success :: C_Success
success = C_Success
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment