Support for stmtListExpr in parser after major keywords. Scaled down version. (#10852)

* Support for stmtListExpr in parser after major keywords
* fixes #4035
This commit is contained in:
cooldome 2019-03-18 10:09:49 +00:00 • committed by Andreas Rumpf
commit 862897dc0f
4 changed files with 54 additions and 12 deletions

View file

@ -29,6 +29,16 @@
- `getImpl` on a `var` or `let` symbol will now return the full `IdentDefs`
tree from the symbol declaration instead of just the initializer portion.
- it is now possible to use statement list expressions after keywords with
indentation: raise, return, discard, yield. This helps parsing code produced
by Nim template expansion where stmtListExpr can appear in place of any expression.
Example:
```nim
raise
var e = new(Exception)
e.msg = "My Exception msg"
e
```
- To use multi-methods, explicit `--multimethods:on` is now needed.