Named arguments in commands + many grammar fixes (#20994)
* Breaking parser changes, implement https://github.com/nim-lang/RFCs/issues/442 Types are separated from expressions and better reflected in the grammar. * add test * more accurate grammar * fix keyword typedescs * accept expressions in proc argument lists * CI "fixes" * fixes * allow full ref expressions again, adapt old tests * cleanup, fix some tests * improve grammar, try and revert semtypes change * restrict sigil binding to identOrLiteral * fix, should have caught this immediately * add changelog entry, fix double not nil bug * correct grammar * change section * fix * real fix hopefully * fix test * support LL(1) for tuples * make grammar.txt too
This commit is contained in:
parent
1564ae650f
commit
4ca2dcb404
18 changed files with 285 additions and 149 deletions
|
|
@ -36,3 +36,12 @@ echo f -4
|
|||
|
||||
echo int -1 # doesn't compile
|
||||
echo int `-` 1 # compiles
|
||||
|
||||
var num = 1
|
||||
num += int 2
|
||||
doAssert num == 3
|
||||
|
||||
import options
|
||||
var opt = some some none int
|
||||
opt = some some none int
|
||||
opt = some none Option[int]
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue