From da89931dccab6770984b49c4a563d35f5ac170c3 Mon Sep 17 00:00:00 2001 From: kou Date: Sat, 21 Apr 2018 06:43:58 +0000 Subject: rexml: Fix XPath concat() implementation * lib/rexml/functions.rb (REXML::Functions.concat): Implement. * test/rexml/test_jaxen.rb: Enable one more test. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63222 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- lib/rexml/functions.rb | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'lib/rexml/functions.rb') diff --git a/lib/rexml/functions.rb b/lib/rexml/functions.rb index 0f91fcd23f..b0029660fa 100644 --- a/lib/rexml/functions.rb +++ b/lib/rexml/functions.rb @@ -186,9 +186,12 @@ module REXML rv end - # UNTESTED def Functions::concat( *objects ) - objects.join + concatenated = "" + objects.each do |object| + concatenated << string(object) + end + concatenated end # Fixed by Mike Stok -- cgit v1.2.3