-interfacesmap2ptr :: InterfacesMap -> IO (Ptr ())
-interfacesmap2ptr cmap = do
- ptr_cmap <- newStablePtr cmap
- return $ castStablePtrToPtr ptr_cmap
-
-ptr2interfacesmap :: Ptr () -> IO InterfacesMap
-ptr2interfacesmap vmap = deRefStablePtr (castPtrToStablePtr vmap :: StablePtr cmap)
-
-
-interfacemethodmap2ptr :: InterfaceMethodMap -> IO (Ptr ())
-interfacemethodmap2ptr cmap = do
- ptr_cmap <- newStablePtr cmap
- return $ castStablePtrToPtr ptr_cmap
-
-ptr2interfacemethodmap :: Ptr () -> IO InterfaceMethodMap
-ptr2interfacemethodmap vmap = deRefStablePtr (castPtrToStablePtr vmap :: StablePtr cmap)
+getInterfaceMethodMap :: IO InterfaceMethodMap
+getInterfaceMethodMap = do
+ ctx <- get_mate_context >>= ptr2ctx
+ return $ ctxInterfaceMethodMap ctx