| In typecheckedSource, I can only access the function definitions with
| type annotations, but not the data type declaration.
| In checkedModuleInfo, I can only access the "Names" of the exported
| entities, and but not their (inferred) types are not present.

You have easy access to the data decls:

In a ModuleInfo is a TypeEnv.
The range of the type env (gotten with typeEnvElts) are TyThings.
A TyThing can be
        a Id
        a Class
        a TyCon
        a DataCon

So just pull out those TyCons and away you go!  (Lots of accessor functions for 
TyCons in module TyCon.)

The Ids are the variables declared in the module, and they each have a type 
(use idType).


In exchange, would you like to document what you have learned?  Here for 
example:
        http://haskell.org/haskellwiki/GHC/As_a_library


Many thanks

Simon
_______________________________________________
Glasgow-haskell-users mailing list
Glasgow-haskell-users@haskell.org
http://www.haskell.org/mailman/listinfo/glasgow-haskell-users

Reply via email to