Permalink
Browse files

remove

  • Loading branch information...
1 parent 84bc033 commit d9d71685a715dbd5a22b06407b41b727ec6a8883 @bobzhang committed Jun 2, 2012
Showing with 0 additions and 24,775 deletions.
  1. BIN c/code/create.o
  2. +0 −519 camlp4/_TZ_19128-vpl331-wlan-library-upenn-edu.tex
  3. +0 −120 camlp4/ast_transform.tex
  4. +0 −120 camlp4/ast_transform_test.tex
  5. +0 −198 camlp4/built_in_extension.tex
  6. BIN camlp4/camlp4_tutorial.dvi
  7. +0 −17,984 camlp4/camlp4_tutorial.log
  8. +0 −456 camlp4/camlp4_tutorial.tex
  9. +0 −3 camlp4/code/jake/json_ast_printer.ml
  10. +0 −87 camlp4/code/jake/json_meta.ml
  11. +0 −6 camlp4/experiment.tex
  12. +0 −693 caption.sty.bak
  13. +0 −17 code/calc/simple.mli
  14. +0 −2 code/ocamlbuild/_build/_log
  15. BIN code/ocamlbuild/_build/myocamlbuild
  16. +0 −113 code/ocamlbuild/_build/myocamlbuild.ml
  17. BIN code/ocamlbuild/_build/myocamlbuild.o
  18. +0 −7 code/ocamlbuild/a.ml
  19. +0 −18 code/ocamlbuild/myocamlbuild.1.ml
  20. +0 −15 code/ocamlbuild/myocamlbuild.2.ml
  21. +0 −21 code/ocamlbuild/myocamlbuild.3.ml
  22. +0 −24 code/ocamlbuild/myocamlbuild.4.ml
  23. +0 −8 code/ocamlbuild/myocamlbuild.5.ml
  24. +0 −66 code/ocamlbuild/myocamlbuild.ml
  25. +0 −773 example/llvm/chap1/parsing/aparser.ml
  26. +0 −4 example/llvm/chap1/parsing/aparser.mli
  27. +0 −773 example/llvm/chap1/parsing/build/aparser.ml
  28. +0 −4 example/llvm/chap1/parsing/build/aparser.mli
  29. +0 −11 lang/posit.tex
  30. +0 −25 lang/private.tex
  31. +0 −101 lex.tex
  32. +0 −5 master.html
  33. +0 −1 master.lof
  34. +0 −1 master.lot
  35. +0 −66 myocamlbuild.ml
  36. +0 −388 ob.tex
  37. +0 −144 pearl/_TZ_78422-seas215-wlan-seas-upenn-edu.tex
  38. +0 −1,614 prv_master.log
  39. +0 −203 runtime/runtime.tex
  40. +0 −3 suthesis-example.lof
  41. +0 −3 suthesis-example.lot
  42. BIN suthesis-example.pdf
  43. +0 −7 suthesis-example.toc
  44. BIN suthesis-template.pdf
  45. +0 −24 test.ml
  46. +0 −1 toolchain/.#ocamlc.tex
  47. +0 −147 toplevel.tex
  48. BIN xcolor.pdf
View
Binary file not shown.

Large diffs are not rendered by default.

Oops, something went wrong.
View
@@ -1,120 +0,0 @@
-\section{Ast Transformation}
-\label{transform}
-
-The filter \emph{Camlp4MapGenerator} reads \emph{OCaml} type
-definitions and generate a class that implements a map traversal. The
-generated class have a method per type you can override to implement a
-\emph{map traversal}.
-
-Camlp4 uses the \textbf{ filter} iteself to bootstrap.
-
-
-\begin{ocamlcode}
-(** file Camlp4Ast.mlast *)
-class map = Camlp4MapGenerator.generated;
-class fold = Camlp4FoldGenerator.generated;
-\end{ocamlcode}
-
-As above, \verb|Camlp4.Ast| has a corresponding map traversal object,
-which could be used by you: (the class was generated by our filter)
-\verb|Ast.map| is a class
-\begin{ocamlcode}
-let b = new Camlp4.PreCast.Ast.map ;;
-val b : Camlp4.PreCast.Ast.map = <obj>
-\end{ocamlcode}
-
-\inputminted[fontsize=\scriptsize, firstline=1,lastline=9]{ocaml}{camlp4/code/ast_add_zero.ml}
-you can write it without sytax extension(very tedious),
-\inputminted[fontsize=\scriptsize, firstline=11,lastline=31]{ocaml}{camlp4/code/ast_add_zero.ml}
-To make life easier, you can write like this
-\inputminted[fontsize=\scriptsize, firstline=32,lastline=38]{ocaml}{camlp4/code/ast_add_zero.ml}
-
-In the module \verb|Camlp4.PreCast.AstFilters|, there are some
-utiliies to do filter over the ast.
-\begin{ocamlcode}
- type 'a filter = 'a -> 'a
- val register_sig_item_filter : Ast.sig_item filter -> unit
- val register_str_item_filter : Ast.str_item filter -> unit
- val register_topphrase_filter : Ast.str_item filter -> unit
- val fold_interf_filters : ('a -> Ast.sig_item filter -> 'a) -> 'a -> 'a
- val fold_implem_filters : ('a -> Ast.str_item filter -> 'a) -> 'a -> 'a
- val fold_topphrase_filters :
- ('a -> Ast.str_item filter -> 'a) -> 'a -> 'a
-\end{ocamlcode}
-
-
-You can also generate map traversal for ocaml type. \emph{put your
- type definition before} you macro, like this
-\inputminted[fontsize=\scriptsize, ]{ocaml}{camlp4/code/ast_map.ml}
-Without filter, you would write the transformer by hand like this
-\inputminted[fontsize=\scriptsize, ]{ocaml}{camlp4/code/ast_map_o.ml}
-
-
-Camlp4 use the filter in \verb|antiquot_expander|, for example in
-\textit{Camlp4Parsers/Camlp4QuotationCommon.ml}, in the definition of
-\verb|add_quotation|, we have
-
-
-\begin{ocamlcode}
-value antiquot_expander = object
- inherit Ast.map as super ;
- method patt : patt -> patt ...
- method expr : expr -> expr ...
-let expand_expr loc loc_name_opt s =
- let ast = parse_quot_string entry_eoi loc s in
- let _ = MetaLoc.loc_name.val := loc_name_opt in
- let meta_ast = mexpr loc ast in
- let exp_ast = antiquot_expander#expr meta_ast in
- exp_ast in
-\end{ocamlcode}
-
-
-Notice that it first invoked \verb|parse_quot_string|, then do some
-transformation, \textbf{ that's how quotation works} !, it will be
-changed to your customized quotation parser, and when it goes to
-antiquot syntax, it will go back to \textbf{ host language
- parser}. Since the host language parser also support quotation
-syntax (due to \textbf{ reflexivity}), so you \textbf{ nest your
- quotation whatever you want.}
-
-There are other transformers as well.
-
-
-Fold
-
-\begin{ocamlcode}
- class x = Camlp4FoldGenerator.generated ;
-\end{ocamlcode}
-
-Meta
-
-
-These functions are what \emph{Camlp4AstLifter uses} to lift the AST,
-and also how \emph{quotations are implemented }
-A example of meta filter could be found here
-
-\inputminted[fontsize=\scriptsize, lastline=40]{ocaml}{camlp4/code/jake/jso}
-
-
-
-LocationStripper (replace location with Loc.ghost)
-
-
-Might be useful when you compare two asts? YES! idea? how to use
-lifter at toplevel, how to beautify our code, without the horribling
-output? (I mean, the qualified name is horrible, but you can solve it
-by open the Module)
-
-
-Camlp4Profiler
-
-
-Inserts profiling code
-
-
-Camlp4TrashRemover
-
-
-Camlp4ExceptionTracer
-
-
@@ -1,120 +0,0 @@
-\section{Ast Transformation}
-\label{transform}
-
-The filter \emph{Camlp4MapGenerator} reads \emph{OCaml} type
-definitions and generate a class that implements a map traversal. The
-generated class have a method per type you can override to implement a
-\emph{map traversal}.
-
-Camlp4 uses the \textbf{ filter} iteself to bootstrap.
-
-
-\begin{ocamlcode}
-(** file Camlp4Ast.mlast *)
-class map = Camlp4MapGenerator.generated;
-class fold = Camlp4FoldGenerator.generated;
-\end{ocamlcode}
-
-As above, \verb|Camlp4.Ast| has a corresponding map traversal object,
-which could be used by you: (the class was generated by our filter)
-\verb|Ast.map| is a class
-\begin{ocamlcode}
-let b = new Camlp4.PreCast.Ast.map ;;
-val b : Camlp4.PreCast.Ast.map = <obj>
-\end{ocamlcode}
-
-\inputminted[fontsize=\scriptsize, firstline=1,lastline=9]{ocaml}{camlp4/code/ast_add_zero.ml}
-you can write it without sytax extension(very tedious),
-\inputminted[fontsize=\scriptsize, firstline=11,lastline=31]{ocaml}{camlp4/code/ast_add_zero.ml}
-To make life easier, you can write like this
-\inputminted[fontsize=\scriptsize, firstline=32,lastline=38]{ocaml}{camlp4/code/ast_add_zero.ml}
-
-In the module \verb|Camlp4.PreCast.AstFilters|, there are some
-utiliies to do filter over the ast.
-\begin{ocamlcode}
- type 'a filter = 'a -> 'a
- val register_sig_item_filter : Ast.sig_item filter -> unit
- val register_str_item_filter : Ast.str_item filter -> unit
- val register_topphrase_filter : Ast.str_item filter -> unit
- val fold_interf_filters : ('a -> Ast.sig_item filter -> 'a) -> 'a -> 'a
- val fold_implem_filters : ('a -> Ast.str_item filter -> 'a) -> 'a -> 'a
- val fold_topphrase_filters :
- ('a -> Ast.str_item filter -> 'a) -> 'a -> 'a
-\end{ocamlcode}
-
-
-You can also generate map traversal for ocaml type. \emph{put your
- type definition before} you macro, like this
-\inputminted[fontsize=\scriptsize, ]{ocaml}{camlp4/code/ast_map.ml}
-Without filter, you would write the transformer by hand like this
-\inputminted[fontsize=\scriptsize, ]{ocaml}{camlp4/code/ast_map_o.ml}
-
-
-Camlp4 use the filter in \verb|antiquot_expander|, for example in
-\textit{Camlp4Parsers/Camlp4QuotationCommon.ml}, in the definition of
-\verb|add_quotation|, we have
-
-
-\begin{ocamlcode}
-value antiquot_expander = object
- inherit Ast.map as super ;
- method patt : patt -> patt ...
- method expr : expr -> expr ...
-let expand_expr loc loc_name_opt s =
- let ast = parse_quot_string entry_eoi loc s in
- let _ = MetaLoc.loc_name.val := loc_name_opt in
- let meta_ast = mexpr loc ast in
- let exp_ast = antiquot_expander#expr meta_ast in
- exp_ast in
-\end{ocamlcode}
-
-
-Notice that it first invoked \verb|parse_quot_string|, then do some
-transformation, \textbf{ that's how quotation works} !, it will be
-changed to your customized quotation parser, and when it goes to
-antiquot syntax, it will go back to \textbf{ host language
- parser}. Since the host language parser also support quotation
-syntax (due to \textbf{ reflexivity}), so you \textbf{ nest your
- quotation whatever you want.}
-
-There are other transformers as well.
-
-
-Fold
-
-\begin{ocamlcode}
- class x = Camlp4FoldGenerator.generated ;
-\end{ocamlcode}
-
-Meta
-
-
-These functions are what \emph{Camlp4AstLifter uses} to lift the AST,
-and also how \emph{quotations are implemented }
-A example of meta filter could be found here
-
-\inputminted[fontsize=\scriptsize, lastline=40]{ocaml}{camlp4/code/jake/jso}
-
-
-
-LocationStripper (replace location with Loc.ghost)
-
-
-Might be useful when you compare two asts? YES! idea? how to use
-lifter at toplevel, how to beautify our code, without the horribling
-output? (I mean, the qualified name is horrible, but you can solve it
-by open the Module)
-
-
-Camlp4Profiler
-
-
-Inserts profiling code
-
-
-Camlp4TrashRemover
-
-
-Camlp4ExceptionTracer
-
-
Oops, something went wrong.

0 comments on commit d9d7168

Please sign in to comment.