blob: 46d1dc587ff3804189ca0246c139bbcd310bf998 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
|
{-# LANGUAGE Arrows #-}
module ShouldCompile where
-- variables bound inside the left argument of -< should be in scope
import Control.Arrow
f :: (Num b, Arrow a) => a b b
f = proc x -> arr (\y -> y-1) -< x
g :: (Num b, Arrow a) => a b b
g = proc x -> (proc y -> returnA -< y-1) -< x
|