Skip to content

Instantly share code, notes, and snippets.

@tanakh
Created May 3, 2010 22:31
Show Gist options
  • Save tanakh/388663 to your computer and use it in GitHub Desktop.
Save tanakh/388663 to your computer and use it in GitHub Desktop.
mport Client
add :: RpcMethod (Int -> Int -> IO Int)
add = method "add"
echo :: RpcMethod (String -> IO String)
echo = method "echo"
main :: IO ()
main = do
conn <- connect "127.0.0.1" 8080
ret <- add conn 1 2
print ret
ret <- echo conn "Hello, MessagePack World!"
print ret
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment