Commit 1d01ed55 authored by simonpj's avatar simonpj
Browse files

Test for Trac #1662

parent 70f39d1e
......@@ -3,3 +3,4 @@ setTestOpts(only_compiler_types(['ghc']))
test('arrowfail001', normal, compile_fail, [''])
test('arrowfail002', normal, compile_fail, [''])
test('arrowfail003', normal, compile_fail, [''])
test('arrowfail004', normal, compile_fail, [''])
{-# LANGUAGE Arrows, ExistentialQuantification #-}
-- Trac #1662
module ShouldFail where
import Control.Arrow
data T = forall a. T a
panic :: (Arrow arrow) => arrow T T
panic = proc (T x) -> do returnA -< T x
\ No newline at end of file
Illegal constructor `T' in a 'proc' pattern
Proc patterns cannot use existentials or GADTs
In the pattern: T x
In the expression: proc (T x) -> do returnA -< T x
In the definition of `panic':
panic = proc (T x) -> do returnA -< T x
Supports Markdown
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