This PR extends `derive(Iterator)` proc macro to support enumeration type when they have variants with a single unnamed field, that implements `IntoIterator`.
Thanks to that, it is now finally possible to derive iterator for the `Shape` type and similar enum types used in AST.
Implements #385
This pull request adjusts AST data structures in Scala and Rust to be compatible, while also fixing a number of JSON format mismatches find along the way. This implements #336.
This commit adds support for suspended blocks in the interpreter and also fixes
a major performance issue with nested thunks that was causing quadratic
evaluation time.
This PR updates JSON serialization in Scala in Rust, so they are compatible, implementing #297. The parser wrapper now uses the real AST in API. Still most of non-trivial use-cases will fail. Once #336 is done, it should finally work.
* save a questionable bit of code
* Fix indentation manager by introducing stack of indents
* more fixes
* ui wip
* HTML Rendering change - first module name, then documentation, last
module functions
* Apply changes requested by @wdanilo
AST lives in `ast` package, that relies significantly on `ast-macros` to generate boilerplate.
Additional `macro-utils` library was split out from `shapely-macros` and `ast-macros`.
The implementation was contributed by @wdanilo , I basically just did some refactoring, documenting and testing.
### Important Notes
* AST is known to be incomplete structurally, finishing it is #336
* AST is missing a number of necessary functions, some of them explicitly marked as FIXME in the code, finishing them is #338
* while I have written some tests, they are not yet part of CI — I want to this smart way (i.e. allowing tests that rely on parser), it is tracked as #340
* AST JSON serialization is incompatible with Scala, solving this is #297
* there is some non-deterministic issue with CI on Windows — I need to look into this closer but it seems to not be related to any Rust parts
Set "-encoding UTF-8" options for javac. Without it compilation fails on platforms where javac defaults to other encoding, like most of Windows that default to whatever code page is active in the system.