Hi,

I don't know what you actually need, but if haskell-src-exts is an option,
it is quite a bit easier to use (definitely easier to understand for me!).
Especially when used together with Uniplate.

For example, for a given piece of AST one can get all the identifiers used
like so:

[ x | Ident x <- universeBi ast ]

Finding where they are bound shouldn't be very hard either.

Hope this helps,
Ozgur

On 23 January 2012 17:33, Christopher Brown <cm...@st-andrews.ac.uk> wrote:

> Hi,
>
> I was wondering if anyone could tell me if it's possible to get an AST
> from the ghc-api decorated with static-semantics?
> In particular, I am interested in use and bind locations for all names in
> the AST together with the module they are bound, etc.
>
> Looking through the online docs, there doesn't seem to be a way to do this.
> Even if I can tell from the AST where a variable is bound that would be
> enough,  if this is by making all names unique and qualified that would be
> better than nothing.
>
> Hope someone can help,
> Chris.
>
_______________________________________________
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe

Reply via email to