diff options
author | simonpj <unknown> | 2000-05-23 11:51:13 +0000 |
---|---|---|
committer | simonpj <unknown> | 2000-05-23 11:51:13 +0000 |
commit | 3a68f09199fb656512347c57f4a7a4f1215a36bd (patch) | |
tree | 3afcc5f968541eacbc482e0bb9cee34a84764591 | |
parent | ef675dbd34a1ccd27ecaa1549a845ec40a6157fd (diff) | |
download | haskell-3a68f09199fb656512347c57f4a7a4f1215a36bd.tar.gz |
[project @ 2000-05-23 11:51:13 by simonpj]
Add tests for result type sigs
-rw-r--r-- | ghc/tests/typecheck/should_compile/tc105.hs | 13 | ||||
-rw-r--r-- | ghc/tests/typecheck/should_compile/tc105.stderr | 0 |
2 files changed, 13 insertions, 0 deletions
diff --git a/ghc/tests/typecheck/should_compile/tc105.hs b/ghc/tests/typecheck/should_compile/tc105.hs new file mode 100644 index 0000000000..f07fb0df19 --- /dev/null +++ b/ghc/tests/typecheck/should_compile/tc105.hs @@ -0,0 +1,13 @@ +-- !!! Scoped type variables in result signatures
+module ShouldCompile where
+
+import PrelST
+import PrelArr
+
+f:: ST s Int
+f:: ST s Int = do
+ v <- newSTRef 5
+ let g :: ST s Int
+ -- ^ should be in scope
+ g = readSTRef v
+ g
diff --git a/ghc/tests/typecheck/should_compile/tc105.stderr b/ghc/tests/typecheck/should_compile/tc105.stderr new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/ghc/tests/typecheck/should_compile/tc105.stderr |