summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/pp.rb4
-rw-r--r--lib/soap/baseData.rb2
-rw-r--r--lib/soap/rpc/proxy.rb11
3 files changed, 11 insertions, 6 deletions
diff --git a/lib/pp.rb b/lib/pp.rb
index bc61484..5e4f20c 100644
--- a/lib/pp.rb
+++ b/lib/pp.rb
@@ -142,7 +142,7 @@ class PP < PrettyPrint
# Object#pretty_print_cycle is used when +obj+ is already
# printed, a.k.a the object reference chain has a cycle.
def pp(obj)
- id = obj.__id__
+ id = obj.object_id
if check_inspect_key(id)
group {obj.pretty_print_cycle self}
@@ -180,7 +180,7 @@ class PP < PrettyPrint
end
def object_address_group(obj, &block)
- id = PointerFormat % (obj.__id__ * 2 & PointerMask)
+ id = PointerFormat % (obj.object_id * 2 & PointerMask)
group(1, "\#<#{obj.class}:0x#{id}", '>', &block)
end
diff --git a/lib/soap/baseData.rb b/lib/soap/baseData.rb
index 0e8b00d..72a6e07 100644
--- a/lib/soap/baseData.rb
+++ b/lib/soap/baseData.rb
@@ -788,7 +788,7 @@ public
if ele.is_a?(Array)
deep_map(ele, &block)
else
- new_obj = block.call(ele)
+ new_obj = yield(ele)
new_obj.elename = ITEM_NAME
new_obj
end
diff --git a/lib/soap/rpc/proxy.rb b/lib/soap/rpc/proxy.rb
index 7dfda62..0797c70 100644
--- a/lib/soap/rpc/proxy.rb
+++ b/lib/soap/rpc/proxy.rb
@@ -345,7 +345,12 @@ private
if @response_style == :rpc
response_rpc(body, mapping_registry, literal_mapping_registry, opt)
else
- response_doc(body, mapping_registry, literal_mapping_registry, opt)
+ ret = response_doc(body, mapping_registry, literal_mapping_registry, opt)
+ if ret.size == 1
+ ret[0]
+ else
+ ret
+ end
end
end
@@ -439,9 +444,9 @@ private
def response_doc(body, mapping_registry, literal_mapping_registry, opt)
if @response_use == :encoded
- return *response_doc_enc(body, mapping_registry, opt)
+ return response_doc_enc(body, mapping_registry, opt)
else
- return *response_doc_lit(body, literal_mapping_registry, opt)
+ return response_doc_lit(body, literal_mapping_registry, opt)
end
end