From: sof Date: Sat, 31 Jul 1999 18:43:48 +0000 (+0000) Subject: [project @ 1999-07-31 18:43:48 by sof] X-Git-Tag: Approximately_9120_patches~5923 X-Git-Url: http://git.megacz.com/?a=commitdiff_plain;h=90d010080d5554c20e2d7cd643f2e94025db5f8d;p=ghc-hetmet.git [project @ 1999-07-31 18:43:48 by sof] nullary recpat reg. test --- diff --git a/ghc/tests/deSugar/should_compile/ds047.hs b/ghc/tests/deSugar/should_compile/ds047.hs new file mode 100644 index 0000000..90078e0 --- /dev/null +++ b/ghc/tests/deSugar/should_compile/ds047.hs @@ -0,0 +1,9 @@ +-- !!! Nullary rec-pats for constructors that hasn't got any labelled +-- !!! fields is legal Haskell, and requires extra care in the desugarer. +module Test where + +data X = X Int [Int] + +f :: X -> Int +f (X _ []) = 0 +f X{} = 1