File tree Expand file tree Collapse file tree 3 files changed +9
-3
lines changed
Expand file tree Collapse file tree 3 files changed +9
-3
lines changed Original file line number Diff line number Diff line change 142142 need to convert to ` string ` . On the JS backend, this is translated directly
143143 to a ` switch ` statement.
144144
145+ - ` foo a = b ` now means ` foo(a = b) ` rather than ` foo(a) = b ` . This is consistent
146+ with the existing behavior of ` foo a, b = c ` meaning ` foo(a, b = c) ` .
147+ This decision was made with the assumption that the old syntax was used rarely;
148+ if your code used the old syntax, please be aware of this change.
149+
145150## Compiler changes
146151
147152- The ` gc ` switch has been renamed to ` mm ` ("memory management") in order to reflect the
Original file line number Diff line number Diff line change @@ -1393,9 +1393,7 @@ proc parseTypeDefValue(p: var Parser): PNode =
13931393 result = parseTypeClass (p)
13941394 else :
13951395 result = simpleExpr (p, pmTypeDef)
1396- if p.tok.tokType == tkNot:
1397- result = binaryNot (p, result )
1398- else :
1396+ if p.tok.tokType != tkNot:
13991397 if result .kind == nkCommand:
14001398 var isFirstParam = false
14011399 while p.tok.tokType == tkComma:
Original file line number Diff line number Diff line change 1+ when false :
2+ type Foo = Bar not nil not nil #[ tt.Error
3+ ^ invalid indentation]#
You can’t perform that action at this time.
0 commit comments