summaryrefslogtreecommitdiff
path: root/paper
diff options
context:
space:
mode:
authorCamil Staps2016-06-07 20:59:05 +0200
committerCamil Staps2016-06-07 20:59:05 +0200
commit6d10eae47eae0af8469dd9a84a7d1df2688cae31 (patch)
treee9c7feb03bc72047fc1ee5e74d6ac7f3d4aed241 /paper
parentMakefile paper (diff)
Processing feedback
Diffstat (limited to 'paper')
-rw-r--r--paper/intro-org.tex7
-rw-r--r--paper/intro-while.tex6
-rw-r--r--paper/intro.tex27
-rw-r--r--paper/paper.tex13
-rw-r--r--paper/while.sty2
5 files changed, 22 insertions, 33 deletions
diff --git a/paper/intro-org.tex b/paper/intro-org.tex
index 3fba1d3..34d45b1 100644
--- a/paper/intro-org.tex
+++ b/paper/intro-org.tex
@@ -6,13 +6,12 @@ the language While~\citep{proganal}. This example language is briefly described
in \autoref{sec:intro:while}. Before discussing our interpreter, we discuss
basic definitions that will be helpful in \autoref{sec:predefs}. Since
extensive research has already been done into lexing and parsing \citep[see
-e.g.][]{yard}, we skip these steps and assume we already have an abstract
-syntax tree (AST). This AST is described in \autoref{sec:ast}. In
+e.g.][]{monads,yard}, we skip these steps and assume we already have an
+abstract syntax tree (AST). This AST is described in \autoref{sec:ast}. In
\autoref{sec:eval} we discuss different possibilities of evaluating
mathematical expressions. Finally, in \autoref{sec:interp} we propose a While
interpreter. We finish by articulating the advantages of functional
interpretation in \autoref{sec:concl}.
\autoref{sec:ftypes} lists the functions and types that the reader is supposed
-to know. If this is not the case: they can easily be looked up using
-Cloogle~\citep{cloogle}.
+to know. Affinity with monads is required.
diff --git a/paper/intro-while.tex b/paper/intro-while.tex
index 77251bd..6751a5f 100644
--- a/paper/intro-while.tex
+++ b/paper/intro-while.tex
@@ -43,16 +43,16 @@ block ends. Lastly, we assume that composition (\whcomp{$S_1$}{$S_2$}) is right
associative. We ignore all whitespace, and do not allow variable names that are
reserved keywords such as \whskip.
-The semantics of these syntax constructs should be intuitive. As an example,
+The semantics of the syntax constructs should be intuitive. As an example,
after executing the following program, \verb$y$ will have been divided by $2$:
\begin{while}
\whcomp%
{\whass{x}{y}}
{\whwhile{\whnotp{\whle{x}{0}}}%
- {\whcomp%
+ {(\whcomp%
{\whass{x}{x-2}}
- {\whass{y}{y-1}}
+ {\whass{y}{y-1}})
}
}
\end{while}
diff --git a/paper/intro.tex b/paper/intro.tex
index 8d76100..191918f 100644
--- a/paper/intro.tex
+++ b/paper/intro.tex
@@ -1,13 +1,13 @@
\section{Introduction}
\label{sec:intro}
-Compilers and interpreters are among the most complex pieces of software
-written to date. Due to the rapid technological development of the last
-decades, programming languages have become increasingly complex, semantically
-speaking. It has become impossible for a programmer to keep in mind the impact
-of their changes on the generated machine code. Developers now constantly rely
-on assumptions about how the language they are using actually works. Intuitive
-semantics may change over time, however, and proper definitions are required
-now that our world relies so principally on software.
+Compilers and interpreters are very complex pieces of software. Due to the
+rapid technological development of the last decades, programming languages have
+become increasingly complex, semantically speaking. It has become impossible
+for a programmer to keep in mind the impact of their changes on the generated
+machine code. Developers now constantly rely on assumptions about how the
+language they are using actually works. Intuitive semantics may change over
+time, however, and proper definitions are required now that our world relies so
+principally on software.
Nowadays, programming languages have semantical specifications as the main link
between programmers and compiler designers. This solves the problem on the
@@ -22,14 +22,15 @@ to efficiently work with semantical specifications --- indeed, functional
programs can be used as the very specification themselves~\citep{fpasspec}.
However, we will not go this far. While functional programs are indeed better
suitable for semantic specifications than natural language, mathematical
-notation gives even more freedom. We therefore suggest tools for the
-implementation of these mathematical definitions in a functional style.
+notation gives even more freedom~\citep[as demonstrated by e.g.][]{proganal}.
+We therefore suggest tools for the implementation of these mathematical
+definitions in a functional style.
Using a high level of abstraction, the gap between specification and
implementation is closed, allowing for quicker correctness checks and better
-maintainable code. The connections between functional languages and
-mathematics let us \emph{prove} properties about code processing systems (for
-example, their correctness with respect to a specification).
+maintainable code. The connections between functional languages and mathematics
+allow us to \emph{prove} properties about code processing systems (for example,
+their correctness with respect to the specification).
\input{intro-org}
\input{intro-while}
diff --git a/paper/paper.tex b/paper/paper.tex
index 724dfc7..4748091 100644
--- a/paper/paper.tex
+++ b/paper/paper.tex
@@ -17,18 +17,7 @@
\def\`#1'{\lit{#1}}
\usepackage{clean}
-\usepackage[dvipsnames]{xcolor}
-\lstdefinestyle{coloured}{
- keywordstyle=\bfseries\color{NavyBlue},
- stringstyle=\ttfamily\color{BrickRed}
-}
-\lstset{
- language=Clean,
- breaklines,
- tabsize=2,
- xleftmargin=\parindent,
- style=coloured
-}
+\lstset{language=Clean,breaklines,tabsize=2,xleftmargin=\parindent}
\usepackage{while}
diff --git a/paper/while.sty b/paper/while.sty
index ed34c41..32d8652 100644
--- a/paper/while.sty
+++ b/paper/while.sty
@@ -9,7 +9,7 @@
\def\whwhile#1#2{\texttt{while~}#1\texttt{~do~}#2}
\def\whnot#1{\texttt{$\lnot$#1}}
-\def\whnotp#1{\texttt{$\lnot$(#1)}}
+\def\whnotp#1{\texttt{$\lnot$}(#1)}
\def\whle#1#2{\texttt{#1$\le$#2}}
\def\axjustifies{\thickness0em\justifies}