shithub: MicroHs

ref: 2f3ccd459aedf6d03eaee5f77d982cbab4c23396
dir: /tests/Foreign.hs/

View raw version
module Foreign(main) where
import Prelude

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

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