Sophie

Sophie

distrib > Mandriva > 9.2 > i586 > by-pkgid > cb5625aca3e4def202f3617de4d26932 > files > 63

c2hs-0.9.9-2mdk.i586.rpm

-- -*-haskell-*-

module Main
where

import C2HS

{#context lib="calls"#}

type TString   = {#type tString#}
type MyStringT = {#type MyStringType#}  -- extract a function type

main :: IO ()
main  = do
	  let barfoo = {#call fun bar#} {#call fun foo#}
	  {#call unsafe baz#} {#call fun foo#} barfoo
	  {#call printString#} {#call fun MyString as myString#}
	  -- test typedef'ed args without argument variable in prototype
	  {#call printString2#} {#call fun MyString as myString#}