
And in partially answering my own question I forgot to add that this gives you a less queasy-making way of identifying the cstr used to create a structure: --Also, the {} pattern can be used for matching a constructor regardless of
the datatype elements even if you don't use records in the data declaration:
data Foo = Bar | Baz Int g :: Foo -> Bool g Bar {} = True g Baz {} = False
Regarding my comments on the lack of good Haskell books, I just checked LYAHFAGG and RWH and neither of them covered either the problem, or the two mechanisms used for a solution. This is very poor, given that the problem is such an obvious one and the solutions are such general mechanisms. I'm pretty sure that Hutton doesn't cover this either - in fact "record syntax" isn't even in the index.