summaryrefslogtreecommitdiff
path: root/testsuite/tests/hiefile/should_compile/ScopesBug.hs
diff options
context:
space:
mode:
Diffstat (limited to 'testsuite/tests/hiefile/should_compile/ScopesBug.hs')
-rw-r--r--testsuite/tests/hiefile/should_compile/ScopesBug.hs13
1 files changed, 13 insertions, 0 deletions
diff --git a/testsuite/tests/hiefile/should_compile/ScopesBug.hs b/testsuite/tests/hiefile/should_compile/ScopesBug.hs
new file mode 100644
index 0000000000..ea87d308d4
--- /dev/null
+++ b/testsuite/tests/hiefile/should_compile/ScopesBug.hs
@@ -0,0 +1,13 @@
+{-# LANGUAGE PatternSynonyms, ViewPatterns #-}
+{-# LANGUAGE ImplicitParams #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE PolyKinds #-}
+
+module ScopesBug where
+
+data Proxy (a :: k) = Proxy
+data Con k (a :: k) = Con (Proxy a)
+
+tyApp :: Con k a -> Proxy a
+tyApp (Con @kx @ax (x :: Proxy ax)) = x :: Proxy (ax :: kx)