>From this discussion 'Contexts on datatype declarations' http://web.archive.org/web/20151208175102/http://code.haskell.org/~dons/haskell-1990-2000/threads.html#04062
It looks like (at least at the time) GHC had separate functions for matching vs building using a constructor. In Hugs, the type for a datatype's constructor(s) is inferred in static.c routine selectCtxt( ) called from depConstrs( ). The type for field (label) selectors is inferred in type.c routine typeSel( ). And it's easy enough to hack that to drop the preds on the selectors, as SPJ advocates in that thread. What I can't find is where Hugs infers the type for a data constructor appearing in matching position. Any hints? Thanks in advance AntC
_______________________________________________ Hugs-Bugs mailing list Hugs-Bugs@haskell.org http://mail.haskell.org/cgi-bin/mailman/listinfo/hugs-bugs