title: How to traverse typed abstract syntax tree in OCaml compiler
body: <p>I'm trying to dump type information of all identifiers in an OCaml project, basically it's the same as traversing the typed abstract syntax tree(<a href="https://github.com/ocaml/ocaml/blob/trunk/typing/typedtree.mli" rel="nofollow">https://github.com/ocaml/ocaml/blob/trunk/typing/typedtree.mli</a>). Since I'm new to OCaml compiler's codebase, I'm not sure whether the Compiler has provided apis so we could easily write a plugin to do the job or we have to hack the compiler code? Also how does this interact with OCamlbuild? Thanks for any hints or advices. </p>