Joan is a tool to clean up C source code generated by the SmallEiffel compiler. It replaces the cryptic mangled names by more meaningful ones, removes distracting comments, and reformats the indention.
The idea behind joan is of course stupid and sick. But as of 2001, SmallEiffel does not yet include native debugging and profiling tools.</p> In some cases, print is good enough. If not, many people use C tools.
Looking at the C source generated by SmallEiffel is not much fund. Naturally, the code optimized to be short in order to compile faster and use less disk space. Joan cleans up this C code, making it easier to interpret.
To get most out of it, it helps to know how to implement exception handling, garbage collection, and multiple inheritance. But even with only some basic C knowledge, you should be able to step through Eiffel routines and read profiler output.
In 2017, when SmallEiffel has an own IDE and tools, joan will not be of much use anymore, except for tracking down Eiffel compiler bugs.
compile -boost -no_split joan
Joan operates on the C source code and
SmallEiffel generates. All of these must exist. It then simple
replaces the "ugly" *.c by a one that will be easier to read.
The general pattern of operation is:
compile -no_split my_class
gcc my_class.c -o my_class
my_class, using all your C debugging and profiling tools.
If you just compiled joan as described above, there still should be three files in
your current directory:
Take a look at
joan.c - it is ugly.
If everything works out, you will have a new
a look at it, it should be nicer (as far as C can be nice).
Joan is released under the GNU GPL. (It has to be like that because it uses code from SmallEiffel's "lib_se".)
Version 1.0, 17-Apr-2001