First class labels
Simon Peyton-Jones
simonpj at microsoft.com
Fri Feb 10 08:04:45 EST 2006
| the concrete proposal is to address one of these remaining issues,
| namely how to identify record field labels as such. for that, I
outlined
| three options, although that outline perhaps wasn't concrete enough:
|
| 1. make label declarations unneccessary (eg., #pointX :: #PointX)
|
| 2. make type sharing expressible (something like the sharing
| constraints in Standard ML's module language, to allow you to
| say when two declarations from different imports refer to the
| same type)
|
| 3. introduce a least upper bound for shared label imports
| (so A and B could just 'import Data.Label(pointX)', which
| would magically provide the shared declaration for pointX)
Thanks for the clarifications. But I am still in the dark. I have
literally no clue about *exactly* what your suggestions would entail.
What would the effect on the type system of (1) be? Or (2) -- is it
just a name-space issue or is it something to do with types. Or (3) --
I have even less clue here. Sorry to be dense
Simon
More information about the Haskell-prime
mailing list