Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
visitors
Project overview
Project overview
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
1
Issues
1
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Container Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
POTTIER Francois
visitors
Commits
f4fcef38
Commit
f4fcef38
authored
Jan 06, 2017
by
POTTIER Francois
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
More doc. Added bibliography.
parent
86ecfd79
Changes
5
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
15659 additions
and
22 deletions
+15659
-22
doc/Makefile
doc/Makefile
+2
-0
doc/english.bib
doc/english.bib
+14517
-0
doc/macros.tex
doc/macros.tex
+2
-0
doc/main.tex
doc/main.tex
+32
-22
doc/plain.bst
doc/plain.bst
+1106
-0
No files found.
doc/Makefile
View file @
f4fcef38
...
...
@@ -11,6 +11,8 @@ ML := $(shell ls ../test/*.ml | grep -v processed)
PROCESSED
:=
$(
patsubst
%.ml,%.processed.ml,
$(ML)
)
%.pdf
:
%.tex $(SOURCES) $(ML) $(PROCESSED)
pdflatex
$*
bibtex
$*
pdflatex
$*
pdflatex
$*
...
...
doc/english.bib
0 → 100644
View file @
f4fcef38
This diff is collapsed.
Click to expand it.
doc/macros.tex
View file @
f4fcef38
...
...
@@ -73,6 +73,8 @@
\newcommand
{
\ocamlbuild
}{
\href
{
https://github.com/ocaml/ocamlbuild/blob/master/manual/manual.adoc
}{
\texttt
{
ocamlbuild
}}
\xspace
}
\newcommand
{
\opam
}{
\href
{
https://opam.ocaml.org/
}{
\texttt
{
opam
}}
\xspace
}
\newcommand
{
\ppxderiving
}{
\href
{
https://github.com/whitequark/ppx
_
deriving
}{
\texttt
{
ppx
\_
deriving
}}
\xspace
}
\newcommand
{
\hashcons
}{
\href
{
https://github.com/backtracking/ocaml-hashcons
}{
\texttt
{
hashcons
}}
\xspace
}
\newcommand
{
\repoURL
}{
https://gitlab.inria.fr/fpottier/visitors
}
\newcommand
{
\srcFile
}
[1]
{
\href
{
\repoURL
/blob/master/src/#1
}{
\texttt
{
#1
}}}
...
...
doc/main.tex
View file @
f4fcef38
...
...
@@ -395,21 +395,8 @@ is found.
\label
{
fig:expr08
}
\end{figure}
\begin{figure}
[p]
\codefollowupgeneral
{
Figures~
\ref
{
fig:expr12
}
and
\ref
{
fig:expr13
}}
\origfirstline
{
expr13double
}{
4
}
\caption
{
A transformation of arithmetic expressions
}
\label
{
fig:expr13double
}
\end{figure}
\begin{figure}
[p]
\codefollowupgeneral
{
Figures~
\ref
{
fig:expr12
}
,
\ref
{
fig:expr13
}
, and~
\ref
{
fig:expr08
}}
\origfirstline
{
expr14
}{
6
}
\caption
{
Conversions between two types of arithmetic expressions
}
\label
{
fig:expr14
}
\end{figure}
\subsection
{
Visitors for open and closed data types
}
\label
{
sec:advanced:openclosed
}
The algebraic data types of arithmetic expressions shown in the previous
section (
\sref
{
sec:intro
}
) are
\emph
{
closed
}
. That is, the type
\oc
|expr|
...
...
@@ -478,22 +465,45 @@ integer constant in an arithmetic expression. This is done in
object that inherits
\oc
|map| and overrides the method
\dataconvisitor
{
EConst
}
.
% ------------------------------------------------------------------------------
% TEMPORARY ICI
% expr13 (expr from oexpr)
% expr08 (hexpr)
% expr14 (moving from expr to hexpr and back)
% TEMPORARY import/export devraient plutôt s'écrire à l'aide de la fonction
% omap sur oexpr?
\begin{figure}
[p]
\codefollowupgeneral
{
Figures~
\ref
{
fig:expr12
}
and
\ref
{
fig:expr13
}}
\origfirstline
{
expr13double
}{
4
}
\caption
{
A transformation of arithmetic expressions
}
\label
{
fig:expr13double
}
\end{figure}
\begin{figure}
[p]
\codefollowupgeneral
{
Figures~
\ref
{
fig:expr12
}
,
\ref
{
fig:expr13
}
, and~
\ref
{
fig:expr08
}}
\origfirstline
{
expr14
}{
6
}
\caption
{
Conversions between two types of arithmetic expressions
}
\label
{
fig:expr14
}
\end{figure}
% TEMPORARY illustration: types ouverts, et comment les fermer
\subsection
{
Visitors for hash-consed abstract syntax trees
}
\label
{
sec:advanced:hashconsed
}
% ------------------------------------------------------------------------------
On top of the open data type
\oc
|oexpr| of the previous section
(
\sref
{
sec:advanced:openclosed
}
), one can define not just the closed data type
\oc
|expr| of ordinary arithmetic expressions, but also other closed data types
of expressions where every node is annotated with information.
As an example, let us define a type
\oc
|hexpr| of hash-consed (that is,
maximally-shared) arithmetic expressions. We follow Filliâtre and Conchon's
approach~
\cite
{
filliatre-conchon-06
}
and use their package
\hashcons
(which
can be installed via
\opam
).
% TEMPORARY illustration: types ouverts, fermés avec hash-consing
% expr08 (hexpr)
% expr14 (moving from expr to hexpr and back)
% ------------------------------------------------------------------------------
\bibliographystyle
{
plain
}
\bibliography
{
english
}
\end{document}
% TEMPORARY
...
...
doc/plain.bst
0 → 100644
View file @
f4fcef38
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment