Commit Graph

21 Commits

Author SHA1 Message Date
Grzegorz Adam Hankiewicz
72a3e21f28 Removes executable bit for text files. 2013-03-16 23:53:07 +01:00
Zahary Karadjov
d0edb1826b adds an option to interleave the generated code with snippets from the original source
Lines from the original source are outputted as comments next to line directives.
Hopefully, this will make debugging codegen problems easier.

Other changes:
The frame setup code now uses a single-line C macro. My motivation was to reduce
the noise in the generated output and make it easier to step over the boiler-plate
code, but counter-intuitively this also improved the overall compilation speed a
little bit so I applied the same treatment to line tracking too (this reduces the size of
the generated files and the explanation is that probably the I/O overhead dominates
the macro expansion costs).
2012-12-02 20:36:29 +02:00
Zahary Karadjov
c67520a7c5 temporary debugging code for the memory leak investigation 2012-11-28 01:15:14 +02:00
Zahary Karadjov
a42545ea3e disables the compile-time rope formatting during bootstrapping 2012-11-28 01:15:14 +02:00
Zahary Karadjov
f644e3079f experimental compile-time rope formatting code 2012-11-28 01:15:13 +02:00
Araq
214c7a2ebd implemented a stack trace profiler 2012-09-15 00:21:10 +02:00
Araq
0171566c98 openarray/varargs split; breaks bootstrapping 2012-08-16 08:34:33 +02:00
Araq
b0c11d3efb made compiler more robust for idetools support 2012-07-30 17:43:22 +02:00
Araq
538b06a123 implements #173 2012-07-28 14:16:08 +02:00
Araq
869a5aa90d doc2 improvements 2012-06-24 02:34:11 +02:00
Araq
76235348f8 extracted documentation generator 2012-05-09 01:50:08 +02:00
Araq
959e370ae9 @ is a sigil-like operator 2012-04-15 10:02:15 +02:00
Araq
fe750a5cf9 performance improvements for ropes 2012-04-13 18:36:55 +02:00
Araq
4f1b89c30c year 2012 for most copyright headers 2012-01-02 23:07:35 +01:00
Araq
a6f90d4cdd first steps to C file merge operation for incremental compilation 2011-10-21 01:06:24 +02:00
Zahary Karadjov
0b197ade6c Multiple C lines corresponding to a single nimrod line are joined together
This patch greatly improves the "step over" operation available in debuggers.
In practice, there are often 4-8 lines of C code generated for each nimrod line
Each such line will be responsible to a single step in the debugger that is
a) not expected by the user
b) taking the user to an incorrect line in the nimrod code

To keep this working, all code generation should use the rope formatting
facilities when producing new lines (i.e. $n and $N).
New semantics for the format string are introduced:
$n means "soft new line" that could be joined/broken when lineDir is enabled.
$N means "hard new line" that will always appear as a new line.

As an alternative to this approach, I also tested producing code like this:
#line "code.nim" 154
foo = bar; \
foo(bar) \

This is better for readability of the final output, but unfortunately it didn't
produce the desired result across all compilers/debuggers.
2011-09-20 14:11:06 +03:00
Araq
dce8949b9b bugfix: 'final' not passed to generic 2011-07-29 01:25:05 +02:00
Araq
922e216b86 got rid of nstrtabs and nhashes modules 2011-06-10 22:49:06 +02:00
Araq
3e9dcc8be5 deprecated system.copy: use system.substr instead 2011-05-14 01:13:44 +02:00
Araq
48dd9679bd := templatable; lexer improvements 2011-04-17 20:17:45 +02:00
Araq
cd292568d7 big repo cleanup 2011-04-12 01:13:42 +02:00