update
[cc1516.git] / deliverables / report / eval.tex
1 \section{Evaluation}
2 All in all we are quite happy with \SPLC. Our added syntactic sugar and the
3 higher order functions make our implementation of \SPL{} quite comfortable to
4 program in. Due to the UNIX style interface it is quite easy to combine
5 usage of the compiler with \SSM.
6
7 There are however of course a lot of things to can be improved. We discuss a few
8 of the most interesting and most pressing issues. First of all error handling
9 in \SPLC{} can be greatly improved. Currently a lot of error happen at position
10 (0,0), most notably all type errors happen at this position. It would be a
11 great improvement in usability if errors would always be reported at the
12 correct position. A second issue is that in \SPLC{} it is not possible to
13 spread a program over multiple modules, when developing larger programs this
14 would be an absolute requirement. Thirdly \SPLC{} currently does not allow for
15 multiple recursion, and all functions need to be declared before they are
16 called. It would be nice to have multiple recursion and to not be forced to
17 structure your program in the order in which functions are called.
18
19 \subsection{Known Bugs}
20 For higher order functions there is a small bug that when an assignment is done
21 to a variable with a higher order function type where the number of arguments
22 is bigger than one and one of the, not-last, arguments is a higher order
23 functien itself the behaviour is unspecified. The bug happens because the
24 function is placed on the heap but the heap is distorted because one of the
25 arguments also modifies the heap. We are certain that with some time we can fix
26 this problem since it is an assembly issue.
27
28 \subsection{Work division}
29 \begin{description}
30 \item [Lexing \& parsing]:
31 \begin{description}
32 \item [\Yard] Pim
33 \item [Lexing] Mart \& Pim
34 \item [Parsing] Mostly Mart, some Pim
35 \item [Sugar] literal string: Mart, literal lists: Pim, Variable
36 arguments printing: Mart, Let-expansion: Pim, Lambdas: Pim
37 \end{description}
38 \item [Semantical analysis]:
39 \begin{description}
40 \item [Sanity checks] Mart
41 \item [Type inference] Mostly Pim, some Mart
42 \item [Lambda lifting] Pim
43 \end{description}
44 \item [Code generation]:
45 \begin{description}
46 \item [RWST monad] Mart
47 \item [Basic Generation] Mart \& Pim
48 \item [Higher order functions] Mart
49 \end{description}
50 \end{description}
51
52 \subsection{Metrics}
53 Between the February the seventh and June the sixth, $18.283$ lines of code
54 been written of which $12.497$ have been removed later on. Detailed records
55 can be found on the open git repository available on
56 \url{https://github.com/dopefishh/cc1516}. Most of the code is written with
57 pair programming.
58
59 The source code of \SPLC{} contains $2051$ lines of code, the rest of the lines
60 of code committed can be attributed to the presentations, test programs and
61 grammar specification.