diff options
author | Araq <rumpf_a@web.de> | 2014-04-09 01:11:52 +0200 |
---|---|---|
committer | Araq <rumpf_a@web.de> | 2014-04-09 01:11:52 +0200 |
commit | 54935e2e70b819853a09ef4582b8cdc2526c1744 (patch) | |
tree | 333121fea6fc3a2d7eec27fb4e3478ab72952275 | |
parent | 0c64849aab957601c71a34f7158eb0e8bd5d4e25 (diff) | |
download | Nim-54935e2e70b819853a09ef4582b8cdc2526c1744.tar.gz |
fixes bootstrapping
-rw-r--r-- | lib/system.nim | 13 | ||||
-rw-r--r-- | todo.txt | 2 |
2 files changed, 10 insertions, 5 deletions
diff --git a/lib/system.nim b/lib/system.nim index a54a25f2f..abb39d0c4 100644 --- a/lib/system.nim +++ b/lib/system.nim @@ -1710,12 +1710,12 @@ proc collectionToString[T](x: T, b, e: string): string = result = b var firstElement = true for value in items(x): - if not(firstElement): result.add(", ") + if not firstElement: result.add(", ") result.add($value) firstElement = false result.add(e) -proc `$`*[T: set](x: T): string = +proc `$`*[T](x: set[T]): string = ## generic ``$`` operator for sets that is lifted from the components ## of `x`. Example: ## @@ -1723,7 +1723,7 @@ proc `$`*[T: set](x: T): string = ## ${23, 45} == "{23, 45}" collectionToString(x, "{", "}") -proc `$`*[T: seq](x: T): string = +proc `$`*[T](x: seq[T]): string = ## generic ``$`` operator for seqs that is lifted from the components ## of `x`. Example: ## @@ -1731,8 +1731,11 @@ proc `$`*[T: seq](x: T): string = ## $(@[23, 45]) == "@[23, 45]" collectionToString(x, "@[", "]") -proc `$`*[T: array](x: T): string = - collectionToString(x, "[", "]") +when false: + # causes bootstrapping to fail as we use array of chars and cstring should + # match better ... + proc `$`*[T, IDX](x: array[IDX, T]): string = + collectionToString(x, "[", "]") # ----------------- GC interface --------------------------------------------- diff --git a/todo.txt b/todo.txt index dcdd6e968..6629bdeeb 100644 --- a/todo.txt +++ b/todo.txt @@ -1,6 +1,8 @@ version 0.9.4 ============= +- document region pointers + Bugs ==== |