nitlanguage
/
nit.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
ed4eb80
)
lib: do not ignore key/values when value is null in Map::join
author
Alexis Laferrière
<alexis.laf@xymus.net>
Sun, 2 Feb 2014 04:47:06 +0000
(23:47 -0500)
committer
Alexis Laferrière
<alexis.laf@xymus.net>
Sun, 2 Feb 2014 22:52:23 +0000
(17:52 -0500)
Signed-off-by: Alexis Laferrière <alexis.laf@xymus.net>
lib/standard/string.nit
patch
|
blob
|
history
diff --git
a/lib/standard/string.nit
b/lib/standard/string.nit
index
e159dfc
..
4326d04
100644
(file)
--- a/
lib/standard/string.nit
+++ b/
lib/standard/string.nit
@@
-1060,15
+1060,15
@@
redef class Map[K,V]
var i = iterator
var k = i.key
var e = i.item
- if e != null then s.append("{k}{couple_sep}{e}")
-
+ s.append("{k}{couple_sep}{e or else "<null>"}")
+
# Concat other items
i.next
while i.is_ok do
s.append(sep)
k = i.key
e = i.item
- if e != null then s.append("{k}{couple_sep}{e}")
+ s.append("{k}{couple_sep}{e or else "<null>"}")
i.next
end
return s.to_s