Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- {-# LANGUAGE ForeignFunctionInterface #-}
- module V8
- (
- hello
- )
- where
- import Foreign.C.Types
- import Foreign.C.String
- foreign import ccall "hello"
- c_hello :: IO CString
- hello :: IO ()
- hello = do
- cstr <- c_hello
- str <- peekCString cstr
- putStrLn str
- return ()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement