Skip to content

Instantly share code, notes, and snippets.

@tautologico
Created June 3, 2011 15:10
Show Gist options
  • Save tautologico/1006493 to your computer and use it in GitHub Desktop.
Save tautologico/1006493 to your computer and use it in GitHub Desktop.
CamlP4 AST for a line of code
Ast.StExp (_loc,
(Ast.ExLet (_loc, Ast.ReNil,
(Ast.BiEq (_loc, (Ast.PaId (_loc, (Ast.IdLid (_loc, "f")))),
(Ast.ExFun (_loc,
(Ast.McArr (_loc, (Ast.PaId (_loc, (Ast.IdLid (_loc, "x")))),
(Ast.ExNil _loc),
(Ast.ExApp (_loc,
(Ast.ExApp (_loc,
(Ast.ExId (_loc, (Ast.IdLid (_loc, "*")))),
(Ast.ExId (_loc, (Ast.IdLid (_loc, "x")))))),
(Ast.ExId (_loc, (Ast.IdLid (_loc, "x")))))))))))),
(Ast.ExApp (_loc, (Ast.ExId (_loc, (Ast.IdLid (_loc, "f")))),
(Ast.ExInt (_loc, "5")))))))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment