Const tuple unpacking (#9964)

* tuple unpacking is now supported for consts

* Move nkConstTuple to the end of TNodeKind

* Add nnkConstTuple in macros.nim

* Fix Formatting
This commit is contained in:
Neelesh Chandola 2018-12-19 15:22:41 +05:30 • committed by Andreas Rumpf
commit 8e90ed0618
4 changed files with 77 additions and 31 deletions

View file

@ -222,7 +222,8 @@ type
nkState, # give a label to a code section (for iterators)
nkBreakState, # special break statement for easier code generation
nkFuncDef, # a func
nkTupleConstr # a tuple constructor
nkTupleConstr, # a tuple constructor
nkConstTuple # a ``const (a, b) = expr`` construct
TNodeKinds* = set[TNodeKind]