Replacing Ty in ExternalCore with IfaceType

Kirsten Chevalier catamorphism at gmail.com
Wed Dec 6 22:42:31 EST 2006


On 12/7/06, Aaron Tomb <atomb at soe.ucsc.edu> wrote:
> In Simon's proposed design, the HsType data type, for instance, is
> shared between Haskell and External Core, which makes sense because
> the two languages have a very similar type structure. However, since
> they have very different term structures, there would be distinct
> HsExpr and ExtCoreExpr data types.

Really? Simon wrote:
>>> * Dump the ExternalCore datatype entirely, or at least move it to
a reference implementation in a completely separate Darcs project.
(The reference impl could read the module, perform a no-op
transformation, and print it out again.)  The data type makes sense as
a way to define what ExtCore is, but it does not make sense as part of
GHC's implementation thereof, I think.

* Use HsSyn for the output side, so that (parse (print p)) is the
identity.  That means that MkExternalCore would generate HsSyn; and
PprExternalCore would print the appropriate subset of HsSyn in ExtCore
syntax.<<<

That sounds to me as if under that scenario, there wouldn't be a
distinct ExtCore datatype, and both Core expressions and Core types
would be represented as HsExprs and HsTypes respectively, but maybe
I'm misreading.

Cheers,
Kirsten

-- 
Kirsten Chevalier* chevalier at alum.wellesley.edu *Often in error, never in doubt
"[Teaching children to read] will make America what we want it to be, a
literate country and a hopefuller country." -- George W. Bush



More information about the Cvs-ghc mailing list