blob: 2e326acd74ef9d9af84252a3f03ce794d972f695 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
|
:set -XHaskell2010
-- Test restricted functionality: FFI
:unset +s
:set -XSafe
:set -XForeignFunctionInterface
foreign import ccall "sin" c_sin' :: Double -> IO Double
x <- c_sin' 1
x
foreign import ccall "sin" c_sin :: Double -> Double
c_sin 1
|