[project @ 2001-08-20 14:44:05 by simonmar]
[ghc-hetmet.git] / ghc / tests / io / stable001 / Main.hs
diff --git a/ghc/tests/io/stable001/Main.hs b/ghc/tests/io/stable001/Main.hs
deleted file mode 100644 (file)
index d0cb982..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
--- This is a rather exciting experiment in using the new call
--- makeStablePtr# and performIO. It doesn't do much but it took an
--- incredible effort to get it to do it.
-
-import Stable
-import GlaExts
-import CString
-
--- module Main(main) where
-
-main = makeStablePtr test      >>= \ stablePtr ->
-       ((_casm_GC_ ``SaveAllStgRegs(); test1(%0); RestoreAllStgRegs();'' stablePtr)
-                                               :: PrimIO ())
-                               >>= \ _ ->
-       return ()
-
-test :: IO Int
-test =
-       let f x = sum [1..x]
-           f :: Int -> Int
-       in 
-       _ccall_ printf
-             (packString "The stable pointer has just been used to print this number %d\n") (f 100)
-                               >>= \ _ ->
-       return 5
-