mirror of
https://github.com/nim-lang/Nim.git
synced 2026-08-28 17:41:45 +00:00
Merge remote-tracking branch 'nim-lang/devel' into emscripten-support
This commit is contained in:
@@ -75,7 +75,7 @@ macro `=>`*(p, b: expr): expr {.immediate.} =
|
||||
identDefs.add(newEmptyNode())
|
||||
of nnkIdent:
|
||||
identDefs.add(c)
|
||||
identDefs.add(newEmptyNode())
|
||||
identDefs.add(newIdentNode("auto"))
|
||||
identDefs.add(newEmptyNode())
|
||||
of nnkInfix:
|
||||
if c[0].kind == nnkIdent and c[0].ident == !"->":
|
||||
@@ -93,7 +93,7 @@ macro `=>`*(p, b: expr): expr {.immediate.} =
|
||||
of nnkIdent:
|
||||
var identDefs = newNimNode(nnkIdentDefs)
|
||||
identDefs.add(p)
|
||||
identDefs.add(newEmptyNode())
|
||||
identDefs.add(newIdentNode("auto"))
|
||||
identDefs.add(newEmptyNode())
|
||||
params.add(identDefs)
|
||||
of nnkInfix:
|
||||
|
||||
@@ -2235,7 +2235,9 @@ proc `$`*[T: tuple|object](x: T): string =
|
||||
firstElement = false
|
||||
result.add(")")
|
||||
|
||||
proc collectionToString[T](x: T, b, e: string): string =
|
||||
proc collectionToString[T: set | seq](x: T, b, e: string): string =
|
||||
when x is seq:
|
||||
if x.isNil: return "nil"
|
||||
result = b
|
||||
var firstElement = true
|
||||
for value in items(x):
|
||||
|
||||
Reference in New Issue
Block a user