[Haskell-cafe] Class-like features for explicit arguments
carter.schonwald at gmail.com
Sat Apr 25 16:39:13 UTC 2015
You miss apprehend. I'm saying that the first class modules encoding in
that paper is expressible using a subset of ghc core.
There IS the subtle issue that type class dictionaries / type classes have
different sharing and strictness semantics than normal userland records.
There's a space Of designs that could provide what you're asking for, and I
do agree that it's worth exploring. I guess The main question is whether or
not it turns into its own research engineering project.
Likewise, to what extent aside from syntactic nicety does implicit
parameters and the punning extensions not suffice?
On Saturday, April 25, 2015, Ertugrul Söylemez <ertesx at gmx.de> wrote:
> > Isn't your associated type here more like a dependent record field/
> > existential that we can kinda expose?
> Not quite. There is still a clear distinction between type and value
> level. You cannot refer to an AT on the value level or to a member
> value on the type level.
> > This does seem to veer into first class module territory. Especially
> > wrt needing first class types in a fashion.
> I think formally there is little difference between a powerful record
> system and a first-class module system. However, even in a
> non-dependent language a first class module could still expect a value
> argument. A record type couldn't do this without essentially making the
> language dependent on the way.
> > Have you had a chance to peruse the Andreas Rossberg 1ml paper on
> > embedding first class modules into f omega that has been circulating?
> > Perhaps there are ideas There that could be adapted. Especially since
> > core is an augmented f omega
> I haven't read it, sorry. My proposal should conform to the current
> core language, as it's mostly just a syntax transformation. The only
> new semantics would be defaults.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Haskell-Cafe