Could you please explain the interface to the type checker?

Hi yhc developers, I'm contemplating the possibility of using Chameleon as a front end (well type checker) for yhc. http://www.comp.nus.edu.sg/~sulzmann/chameleon/download/haskell.html Would one of you be able to describe the interface of the type checker (which I presume is Type.typeTopDecls)? Cheers, Bernie. PS I don't want to tread on anyone's toes, so if you have a fancy new type checker in the pipeline I would like to hear about that too.

Bernie Pope
I'm contemplating the possibility of using Chameleon as a front end (well type checker) for yhc.
Interesting idea. Could be useful.
I don't want to tread on anyone's toes, so if you have a fancy new type checker in the pipeline I would like to hear about that too.
No-one is currently working on replacing the type system in yhc.
Would one of you be able to describe the interface of the type checker (which I presume is Type.typeTopDecls)?
typeTopDecls :: ((TokenId,IdKind) -> Id) -> Maybe [Id] -> IntState -> [ClassCode (Exp Id) Id] -> Decls Id -> ([ClassCode (Exp Id) Id],Decls Id,IntState) First argument ((TokenId,IdKind) -> Id) is a mapping from the literal name (+ IdKind = function,method,class etc) of an identifier to its Id (lookup key) in the symbol table. Second arg is the current list of defaults: Maybe [Id] Third arg is the running state of the compiler IntState It contains the symbol table, command-line flags, and any accumulated error messages. Fourth arg [ClassCode (Exp Id) Id] and fifth arg Decls Id are the abstract syntax tree, with strongly-connected component analysis already performed, and all class and instance decls hoisted out into a separate list. The Result ([ClassCode (Exp Id) Id],Decls Id,IntState) is a new AST, and a new running state. Any type errors have been written into the IntState. Regards, Malcolm

Hi Bernie, Probably the most useful person to speak to about the Yhc type checker is Malcolm since the type checker hasn't been changed from nhc98. In particular Malcolm's "Summer of Code" student studied the interface to the type checker in depth. There have been several proposals at a new type checker, and at least one attempt with the google summer of code project - but so far these have all failed to produce anything. Anyway hope that helps :-) Thanks Tom Bernie Pope wrote:
Hi yhc developers,
I'm contemplating the possibility of using Chameleon as a front end (well type checker) for yhc.
http://www.comp.nus.edu.sg/~sulzmann/chameleon/download/haskell.html
Would one of you be able to describe the interface of the type checker (which I presume is Type.typeTopDecls)?
Cheers, Bernie.
PS
I don't want to tread on anyone's toes, so if you have a fancy new type checker in the pipeline I would like to hear about that too. _______________________________________________ Yhc mailing list Yhc@haskell.org http://www.haskell.org/mailman/listinfo/yhc

Ah Looks like Malcolm did reply to this :-) Thomas Shackell wrote:
Hi Bernie,
Probably the most useful person to speak to about the Yhc type checker is Malcolm since the type checker hasn't been changed from nhc98. In particular Malcolm's "Summer of Code" student studied the interface to the type checker in depth.
There have been several proposals at a new type checker, and at least one attempt with the google summer of code project - but so far these have all failed to produce anything.
Anyway hope that helps :-)
Thanks
Tom
Bernie Pope wrote:
Hi yhc developers,
I'm contemplating the possibility of using Chameleon as a front end (well type checker) for yhc.
http://www.comp.nus.edu.sg/~sulzmann/chameleon/download/haskell.html
Would one of you be able to describe the interface of the type checker (which I presume is Type.typeTopDecls)?
Cheers, Bernie.
PS
I don't want to tread on anyone's toes, so if you have a fancy new type checker in the pipeline I would like to hear about that too. _______________________________________________ Yhc mailing list Yhc@haskell.org http://www.haskell.org/mailman/listinfo/yhc
_______________________________________________ Yhc mailing list Yhc@haskell.org http://www.haskell.org/mailman/listinfo/yhc
participants (3)
-
Bernie Pope
-
Malcolm Wallace
-
Thomas Shackell