shithub: MicroHs

ref: d7ca6737c91c2c5e71c3617426d25ebb4a81d290
dir: /tests/Foreign.hs/

View raw version
module Foreign(main) where
import Prelude

foreign import ccall "llabs" iabs :: Int -> IO Int

main :: IO ()
main = do
  x1 <- iabs (3 - 8)
  putStrLn $ show x1
  x2 <- iabs (10 - 8)
  putStrLn $ show x2