[Haskell-cafe] Control.Concurrent export/import weirdness

Jason Dusek jason.dusek at gmail.com
Mon Apr 13 06:15:15 EDT 2009


  Why is this function exported then imported?

    foreign export ccall forkOS_entry
        :: StablePtr (IO ()) -> IO ()

    foreign import ccall "forkOS_entry" forkOS_entry_reimported
        :: StablePtr (IO ()) -> IO ()

    forkOS_entry :: StablePtr (IO ()) -> IO ()
    forkOS_entry stableAction = do
            action <- deRefStablePtr stableAction
            action


--
Jason Dusek


More information about the Haskell-Cafe mailing list