From: Simon Marlow Date: Tue, 25 Sep 2007 12:11:39 +0000 (+0000) Subject: document float2Int# and double2Int# X-Git-Url: http://git.megacz.com/?p=ghc-hetmet.git;a=commitdiff_plain;h=ee780821a6416a059edd978af340dc89d7447d63 document float2Int# and double2Int# --- diff --git a/compiler/prelude/primops.txt.pp b/compiler/prelude/primops.txt.pp index 13ce302..335a717 100644 --- a/compiler/prelude/primops.txt.pp +++ b/compiler/prelude/primops.txt.pp @@ -545,6 +545,10 @@ primop DoubleDivOp "/##" Dyadic primop DoubleNegOp "negateDouble#" Monadic Double# -> Double# primop Double2IntOp "double2Int#" GenPrimOp Double# -> Int# + {Truncates a {\tt Double#} value to the nearest {\tt Int#}. + Results are undefined if the truncation if truncation yields + a value outside the range of {\tt Int#}.} + primop Double2FloatOp "double2Float#" GenPrimOp Double# -> Float# primop DoubleExpOp "expDouble#" Monadic @@ -652,6 +656,9 @@ primop FloatDivOp "divideFloat#" Dyadic primop FloatNegOp "negateFloat#" Monadic Float# -> Float# primop Float2IntOp "float2Int#" GenPrimOp Float# -> Int# + {Truncates a {\tt Float#} value to the nearest {\tt Int#}. + Results are undefined if the truncation if truncation yields + a value outside the range of {\tt Int#}.} primop FloatExpOp "expFloat#" Monadic Float# -> Float#