-
Notifications
You must be signed in to change notification settings - Fork 0
/
appendix02.tex
28 lines (25 loc) · 1.4 KB
/
appendix02.tex
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
\chapter{Using Janus}
The~Janus interpreter is included in the~\texttt{janus.zip} attachment as well
as available in a GitHub repository at \url{https://github.com/svobot/janus}.
The~interpreter can be compiled using the Cabal package manager and the~GHC
compiler. Both come with the~Haskell Platform~[\citeauthor{haskell_platform}].
Janus can be compiled and run using the~command:
\begin{center}
\texttt{cabal run janusc}
\end{center}
The~software was tested using Cabal version 3.4.0.0 and GHC version 8.10.4.
The~code is documented with Haddock-style comments. The~HTML version of
the~documentation can be generated using the~command:
\begin{center}
\texttt{cabal haddock --enable-documentation}
\end{center}
Modules of the~interpreter described in the~section \nameref{sec:architecture}
can be found in the~folder \texttt{src/Janus} and the~tests in the~folder
\texttt{test}. In the~folder \texttt{app} is the~module \texttt{Main}, which
serves as the~entry point for the~executable. Folder \texttt{lib} contains
a~file with a~few interesting functions that can be conveniently loaded into
the~scope of the~interpreter using the~\emph{load} command: there are
the~first and second element projections for the~multiplicative pair in
the~erased part of the~theory, \texttt{proj1} and \texttt{proj2}, the~of course
type constructor $\oc_\omega S$ (\texttt{ofcW}), and an~eliminator for values of
this type \texttt{ofcElim}.