---!!! ds001 -- simple function and pattern bindings
+-- !!! ds001 -- simple function and pattern bindings
--
-- this tests ultra-simple function and pattern bindings (no patterns)
---!!! ds002 -- overlapping equations and guards
+-- !!! ds002 -- overlapping equations and guards
--
-- this tests "overlapping" variables and guards
---!!! ds003 -- list, tuple, lazy, as patterns
+-- !!! ds003 -- list, tuple, lazy, as patterns
--
module Test where
---!!! ds004 -- nodups from SLPJ p 79
+-- !!! ds004 -- nodups from SLPJ p 79
--
module Test where
---!!! ds005 -- mappairs from SLPJ Ch 5'
+-- !!! ds005 -- mappairs from SLPJ Ch 5'
--
-- this simply tests a "typical" example
---!!! ds006 -- v | True = v+1 | False = v (dead code elim)
+-- !!! ds006 -- v | True = v+1 | False = v (dead code elim)
--
module Test where
---!!! ds007 -- simple local bindings
+-- !!! ds007 -- simple local bindings
module ShouldSucceed where
---!!! ds008 -- free tyvars on RHSs
+-- !!! ds008 -- free tyvars on RHSs
--
-- these tests involve way-cool TyApps
---!!! ds009 -- simple list comprehensions
+-- !!! ds009 -- simple list comprehensions
module SimpleListComp where
---!!! ds010 -- deeply-nested list comprehensions
+-- !!! ds010 -- deeply-nested list comprehensions
module Test where
---!!! ds011 -- uses of "error"
+-- !!! ds011 -- uses of "error"
module Tests where
---!!! ds012 -- simple Integer arithmetic
+-- !!! ds012 -- simple Integer arithmetic
--
module Tests where
---!!! ds013 -- simple Rational arithmetic
+-- !!! ds013 -- simple Rational arithmetic
module Tests where
---!!! ds014 -- character and string literals
---!!! really should add ALL weird forms...
+-- !!! ds014 -- character and string literals
+-- !!! really should add ALL weird forms...
module Tests where
---!!! ds015 -- lambdas
+-- !!! ds015 -- lambdas
--
module Tests where
---!!! ds016 -- case expressions
+-- !!! ds016 -- case expressions
--
module Tests where
---!!! ds017 -- let expressions
+-- !!! ds017 -- let expressions
--
module Tests where
---!!! ds018 -- explicit lists and tuples
+-- !!! ds018 -- explicit lists and tuples
--
module Tests where
---!!! ds019 -- mixed var and uni-constructor pats
+-- !!! ds019 -- mixed var and uni-constructor pats
module Test where
---!!! ds020 -- lazy patterns (in detail)
+-- !!! ds020 -- lazy patterns (in detail)
--
module Test where
---!!! ds021 -- hairier uses of guards
+-- !!! ds021 -- hairier uses of guards
module Test where
---!!! ds022 -- literal patterns (wimp version)
+-- !!! ds022 -- literal patterns (wimp version)
--
module Tests where
---!!! ds023 -- overloading eg from section 9.2
+-- !!! ds023 -- overloading eg from section 9.2
--
module Tests where
---!!! ds024 -- correct types on ConPatOuts
+-- !!! ds024 -- correct types on ConPatOuts
-- do all the right types get stuck on all the
-- Nils and Conses?
---!!! ds025 -- overloaded assoc -- AbsBinds
+-- !!! ds025 -- overloaded assoc -- AbsBinds
module Util where
---!!! ds026 -- classes -- incl. polymorphic method
+-- !!! ds026 -- classes -- incl. polymorphic method
module ShouldSucceed where
---!!! ds027 -- simple instances
+-- !!! ds027 -- simple instances
--
module Test where
---!!! ds028: failable pats in top row
+-- !!! ds028: failable pats in top row
module ShouldSucceed where
---!!! ds029: pattern binding with guards (dubious but valid)
+-- !!! ds029: pattern binding with guards (dubious but valid)
--
module Test where
---!!! ds030: checks that types substituted into binders
+-- !!! ds030: checks that types substituted into binders
--
module Test where
---!!! recursive funs tangled in an AbsBind
+-- !!! recursive funs tangled in an AbsBind
module ShouldSucceed where
---!!! getting top-level dependencies right
+-- !!! getting top-level dependencies right
--
module Test where
---!!! mutually-recursive methods in an instance declaration
+-- !!! mutually-recursive methods in an instance declaration
--
module Test where
---!!! AbsBinds with tyvars, no dictvars, but some dict binds
+-- !!! AbsBinds with tyvars, no dictvars, but some dict binds
--
module ShouldSucceed where
---!!! Jon Hill reported a bug in desugaring this in 0.09
---!!! (recursive with n+k patts)
+-- !!! Jon Hill reported a bug in desugaring this in 0.09
+-- !!! (recursive with n+k patts)
--
module ShouldSucceed where
---!!! make sure correct type applications get put in
---!!! when (:) is saturated.
+-- !!! make sure correct type applications get put in
+-- !!! when (:) is saturated.
module ShouldSucceed where
---!!! Another bug in overloaded n+k patts
+-- !!! Another bug in overloaded n+k patts
--
main = print ((4::Int) ^^^^ (6::Int))
data X = A {a :: Int} | B {a :: Int}
-f x = let A {a} = x
+f x = let A {a=a} = x
in a
main = print (f (A {a = 3}))