[project @ 1997-05-26 05:58:06 by sof]
[ghc-hetmet.git] / ghc / compiler / tests / ccall / cc004.hs
index 6dee399..f53c61d 100644 (file)
@@ -1,7 +1,7 @@
 --!!! cc004 -- ccall with synonyms, polymorphic type variables and user type variables.
 module Test where
 
-import PreludeGlaST
+import GlaExts
 
 -- Since I messed up the handling of polymorphism originally, I'll
 -- explicitly test code with UserSysTyVar (ie an explicit polymorphic
@@ -10,16 +10,14 @@ import PreludeGlaST
 foo = _ccall_ f        `thenADR` \ a -> returnPrimIO (a + 1)
  where 
    thenADR :: PrimIO a -> (a -> PrimIO b) -> PrimIO b
-   m `thenADR` k  = \ s -> case m s of
-                         (a,t) -> k a t
+   thenADR = thenPrimIO
 
 -- and with a PolySysTyVar (ie no explicit signature)
 
 bar = _ccall_ f        `thenADR` \ a -> returnPrimIO (a + 1)
  where 
    -- thenADR :: PrimIO a -> (a -> PrimIO b) -> PrimIO b
-   m `thenADR` k  = \ s -> case m s of
-                         (a,t) -> k a t
+   thenADR = thenPrimIO
 
 -- and with a type synonym