Commit 0a1ef8e3 authored by simonmar's avatar simonmar
Browse files

[project @ 2002-04-25 09:05:07 by simonmar]

Stable pointer test from Bernie Pope.
parent e47a1305
......@@ -23,5 +23,6 @@ test "show001" { vtr("","","") }
test "stableptr001" { lang_vtr("","+RTS -K4m -RTS","") }
test "stableptr003" { lang_vtr("","","") }
test "stableptr004" { lang_vtr("","+RTS -K4m -RTS","") }
test "stableptr005" { lang_vtr("","","") }
test "text001" { vtr("","","") }
test "weak001" { lang_vtr("-fglasgow-exts","","") }
-- !!! triggered a temporary bug in freeStablePtr around 20020424
module Main where
import StablePtr (newStablePtr, freeStablePtr)
data Foo = A | B | C | D
main :: IO ()
main = do aSPtr <- newStablePtr A
bSPtr <- newStablePtr B
cSPtr <- newStablePtr C
cSPtr' <- newStablePtr C
freeStablePtr aSPtr
freeStablePtr bSPtr
freeStablePtr cSPtr
freeStablePtr cSPtr'
aSPtr <- newStablePtr A
bSPtr <- newStablePtr B
cSPtr <- newStablePtr C
dSPtr <- newStablePtr D
print "Hello World"
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment