Commit graph

113 commits

Author SHA1 Message Date
Adam Strzelecki
13b57dbc2f Introduce {.noRewrite.} expr pragma disabling TR
Term rewriting macros/templates are currently greedy and they will rewrite as
long as there is a match. So there was no way to ensure some rewrite happens
only once, eg. when rewriting term to same term plus extra content.

With new macro we can actually prevent further rewriting on marked expr or
stmts, eg. with given example echo(...) will be rewritten just once:

  template pwnEcho{echo(x)}(x: expr) =
    {.noRewrite.}: echo("pwned!")

  echo "ab"
2015-06-02 21:38:53 +02:00
Araq
f6ff01572e breaking change: 'concept' is now a keyword and used instead of 'generic' 2015-03-23 13:10:18 +01:00
Araq
910ef7b2d1 'constructor' pragma for C++ support 2015-03-18 11:42:37 +01:00
Guillaume Gelin
3119fe087d Happy new year! 2015-01-06 15:26:33 +01:00
Araq
85cc5a6a1f destuctors are experimental; 'func' is now a keyword 2014-12-10 01:57:08 +01:00
Araq
4b7de4dc5e implemented 'experimental' switch 2014-12-05 10:09:29 +01:00
Araq
e27ab36731 implements 'defer' 2014-12-04 10:12:32 +01:00
Araq
7916b1f9aa implemented 'guard' annotation 2014-09-21 18:39:00 +02:00
Araq
2781fea9e2 Nimrod renamed to Nim 2014-08-28 09:38:14 +02:00
Araq
057b53e139 'lambda' is no keyword anymore 2014-08-08 02:24:19 +02:00
Araq
9673e4f2df progress on deepCopy 2014-08-01 23:40:48 +02:00
Araq
3b69a8d27a New concurrency model: next steps 2014-04-19 22:24:43 +02:00
Araq
8e08ff559f first version of 'spawn' 2014-04-16 08:44:57 +02:00
Araq
b961e47bfe new concurrency model: first steps; shared is not a keyword anymore 2014-04-14 08:45:43 +02:00
Audun Wilhelmsen
1e45bb79ab Added support for {.packed.} pragma on objects
Added tests for packed and union pragmas
2014-03-18 21:11:57 +01:00
Araq
5506e8491d implemented 'union' and 'unchecked' pragmas 2014-03-05 20:19:04 +01:00
Araq
ab72377ce6 renamed noStackFrame to asmNoStackFrame 2014-02-18 09:57:59 +01:00
Araq
92b8fac94a case consistency part 4 2013-12-27 23:10:36 +01:00
Araq
b76729df1c Merge branch 'master' of https://github.com/Araq/Nimrod into vm2
Conflicts:
	web/news.txt
2013-12-23 01:23:16 +01:00
Araq
132b6b3efe implemented 'injectStmt'; more debug support 2013-12-16 22:26:17 +01:00
Araq
c0a3d44060 bugfix: keywords are sorted 2013-12-05 10:45:36 +01:00
Zahary Karadjov
b5d833b329 implemented the using statement 2013-08-31 19:40:36 +03:00
Zahary Karadjov
28d9398de7 implemented delegators and improved the error messages of unmatched type classes 2013-08-26 23:29:24 +03:00
Araq
d53f313599 implemented computed goto support 2013-08-13 11:21:02 +02:00
Araq
139562cc64 implements the 'codegenDecl' pragma 2013-06-27 18:13:11 +02:00
Araq
23ef565a3c implemented large parts of the 'not nil' checking 2013-06-09 23:29:43 +02:00
Zahary Karadjov
f44a4362bb added a `noforward` pragma that enables a new compilation strategy
not requiring forward declarations on a per-module basis
2013-05-11 22:47:37 +03:00
Grzegorz Adam Hankiewicz
72a3e21f28 Removes executable bit for text files. 2013-03-16 23:53:07 +01:00
Araq
d0de1fc336 made 'shared' a keyword 2012-11-22 07:53:50 +01:00
Araq
48a62af3b1 implemented 'tags' pragma 2012-11-11 22:03:41 +01:00
Araq
2133fbfcce bugfix: wrong assertions for C++ code generation; some solaris support; first steps to an effect system 2012-10-30 22:29:03 +01:00
Araq
3ef146b0ea 'mixin' and 'interface' are now keywords 2012-09-22 10:04:31 +02:00
Araq
1d14cb1ad8 next steps towards term rewriting macros; simple examples work 2012-08-30 22:55:32 +02:00
Araq
da190876de next steps to hygienic templates 2012-08-20 08:44:17 +02:00
Araq
5e15dec175 first steps to make templates hygienic 2012-08-20 01:13:13 +02:00
Araq
0b509127d2 documentation improvements; added system.gorge (for Araq's fun) 2012-06-22 08:30:55 +02:00
Zahary Karadjov
ce933c90a4 destructor pragma 2012-06-07 03:32:40 +03:00
Zahary Karadjov
337e1ecc7c codegen for user-defined destructors 2012-05-25 19:02:14 +03:00
Zahary Karadjov
38710b614f more Objective-C and C keywords are now escaped 2012-04-18 19:50:32 +03:00
Zahary Karadjov
f25c638dc4 experimental support for preserving local variable names in the generated code 2012-04-13 21:03:49 +03:00
Zahary Karadjov
6d80583d5a Added `global` pragma that can be used to introduce new global variables from within procs 2012-04-05 20:43:22 +03:00
Zahary Karadjov
e43f8d842b merged branch overloading-for-macros 2012-03-19 12:06:38 +02:00
Zahary Karadjov
e5bd3b5b97 bootstraps fine with overloadable templates 2012-03-14 21:00:42 +02:00
Araq
c25ffbf262 first steps for cleaner static/const distinction 2012-03-13 02:01:56 +01:00
Araq
375c95d3ad bugfix: no need for arrows to be new token kinds 2012-02-12 18:56:36 +01:00
Zahary Karadjov
560a3bad28 `do' keyword in the grammar for lambda blocks 2012-02-10 14:50:35 +02:00
Araq
8d19a93f1a pragma on/off improvements; endb rewritten 2012-01-28 23:22:44 +01:00
Araq
8aa4e46707 implemented incompleteStruct pragma; embedded debugger works with posix module 2012-01-05 00:46:51 +01:00
Araq
4f1b89c30c year 2012 for most copyright headers 2012-01-02 23:07:35 +01:00
Araq
2de98d9e05 new pragma: 'noinit' 2011-11-25 15:33:58 +01:00