Merge remote-tracking branch 'nim-lang/devel' into emscripten-support
This commit is contained in:
commit
df65082370
10 changed files with 61 additions and 43 deletions
|
|
@ -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):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue