Sébastien Villemot
74ef3457b4
Use secure URL for link to GNU licenses
2021-06-09 17:21:00 +02:00
Sébastien Villemot
ec779235ea
Macro-processor: move environment out of node classes
...
This completes the separation of parse trees from their evaluation.
Closes : #32
2020-12-07 17:29:05 +01:00
Houtan Bastani
28b98c7c0e
Rework the function that handles the macro-expansion of the .mod file
2020-02-20 15:30:46 +01:00
Houtan Bastani
1dbbd87d3d
Remove options `noemptylinemacro` and `nolinemacro`; add option `linemacro`
...
This only concerns the situation when `savemacro` is also passed.
When `linemacro` is passed, the macro expanded .mod file is the same as before
When `linemacro` is not passed, the macro expanded .mod file is equivalent to what it was before when both `noemptylinemacro` and `nolinemacro` were passed.
closes #44
closes #45
2020-02-05 15:19:01 +01:00
Houtan Bastani
6284e991fc
macro processor: remove unnecessary type specifiers
2020-02-04 11:12:41 +01:00
Houtan Bastani
148aa9d924
macro processor: simplify handling of `@#define`
2020-01-29 14:52:01 +01:00
Houtan Bastani
e9049aa81f
use prefix notation `R"()"` for quote in quotes
2020-01-16 16:24:21 +01:00
Houtan Bastani
6d1c2ca82b
macro processor: allow colon-separated arrays as command-line defines
...
colon-separated command line arguments such as
```
dynare <<.mod file>> -DA=1:5 -DAA=1:2:5
```
are now translated as:
```
@#define C = [2, 3, 4, 5, 6]
@#define CC = [2, 5]
```
2020-01-16 16:24:21 +01:00
Houtan Bastani
f00d7c4b4c
macro processor: fix bug where command line arguments that began with an integer were being treated as integers even if they weren't (e.g. dates)
2020-01-16 13:09:42 +01:00
Sébastien Villemot
e2d5a83592
Global reindentation
2019-12-20 16:59:30 +01:00
Sébastien Villemot
031c0cff5f
Various code simplifications and modernizations
2019-12-16 19:42:59 +01:00
Houtan Bastani
ef4710cdb1
macro processor: fix for loops
2019-10-29 11:21:09 +01:00
Houtan Bastani
4866bb5902
macro processor: use C++17 structured bindings in for loops
2019-10-29 11:20:21 +01:00
Houtan Bastani
1291320053
macro processor: handle empty files
2019-10-04 11:18:03 +02:00
Houtan Bastani
031bc62f3a
macro processor: use filesystem after move to C++17, closes #31
...
ancillary to this change is the move of `paths` out of the Driver class into an argument to parsing/evaluation #32
2019-10-03 14:24:47 +02:00
Houtan Bastani
d7e70a4063
macro processor: fix bug: interpret @#include at node level instead of at the Driver level
2019-10-02 17:39:11 +02:00
Houtan Bastani
310f3936fe
macro processor: fix bug: interpret @#includepath at node level instead of at the Driver level
2019-10-02 17:39:05 +02:00
Houtan Bastani
cd99bb3af9
macro processor: Make @#include and @#includepath immutable
2019-08-19 18:20:53 +02:00
Houtan Bastani
63b2117587
macro processor: remove unnecessary includes
2019-06-27 13:57:19 +02:00
Houtan Bastani
b8205a49df
Revert "macro processor: allow @#includepath to accept a colon-separated list of paths"
...
This reverts commit 12b09073e3
.
2019-06-24 14:39:35 +02:00
Houtan Bastani
12b09073e3
macro processor: allow @#includepath to accept a colon-separated list of paths
2019-06-24 12:20:48 +02:00
Houtan Bastani
17e040f3f6
macro processor 2.0
2019-06-21 16:45:17 +02:00