It seems to be impossible to denote an empty row, so the type Rec () is
ill-formed. This would be useful in conjunction with row synonyms, as in

        type AddA r = (a::Integer | r)
        x = (a=2) :: Rec (AddA ())

which generates the error message

        ERROR "Junk.hs" (line 2): Kind error in constructor application
        *** expression     : AddA ()
        *** constructor    : ()
        *** kind           : *
        *** does not match : row

Maybe the type checker should infer for each occurrence of () whether it
is a row or a type?

John Hughes

Reply via email to