mercurial/templateutil.py
changeset 38228 8bded7eae26c
parent 38226 7824783a6d5e
child 38229 7701c2d4a438
--- a/mercurial/templateutil.py	Sat Apr 21 17:00:21 2018 +0900
+++ b/mercurial/templateutil.py	Sat Apr 21 17:15:11 2018 +0900
@@ -189,12 +189,8 @@
         yield self.tomap()
 
     def join(self, context, mapping, sep):
-        # TODO: just copies the old behavior where a value was a generator
-        # yielding one item, but reconsider about it. join() over a string
-        # has no consistent result because a string may be a bytes, or a
-        # generator yielding an item, or a generator yielding multiple items.
-        # Preserving all of the current behaviors wouldn't make any sense.
-        return self.show(context, mapping)
+        w = makewrapped(context, mapping, self._value)
+        return w.join(context, mapping, sep)
 
     def show(self, context, mapping):
         # TODO: switch gen to (context, mapping) API?