- BlackBox: name: GHC.Base.remInt kind: Declaration type: 'remInt :: Int -> Int -> Int' template: |- ~RESULT <= ~ARG[0] rem ~ARG[1] -- pragma translate_off when (~ARG[1] /= 0) else (others => 'X') -- pragma translate_on ; - BlackBox: name: GHC.Base.divInt kind: Declaration type: 'divInt :: Int -> Int -> Int' template: |- -- divInt begin ~GENSYM[divInt][0] : block signal ~GENSYM[quot_res][1] : ~TYP[1]; begin ~SYM[1] <= ~ARG[0] / ~ARG[1] -- pragma translate_off when (ARG[1] /= 0) else (others => 'X') -- pragma translate_on ; ~RESULT <= ~SYM[1] - 1 when ((~ARG[0] = abs ~ARG[0]) /= (~ARG[1] = abs ~ARG[1])) else ~SYM[1]; end block; -- divInt end - BlackBox: name: GHC.Base.modInt kind: Declaration type: 'modInt :: Int -> Int -> Int' template: |- ~RESULT <= ~ARG[0] mod ~ARG[1] -- pragma translate_off when (~ARG[1] /= 0) else (others => 'X') -- pragma translate_on ; - BlackBox: name: GHC.Base.quotInt kind: Declaration type: 'quotInt :: Int -> Int -> Int' template: |- ~RESULT <= ~ARG[0] / ~ARG[1] -- pragma translate_off when (~ARG[1] /= 0) else (others => 'X') -- pragma translate_on ;