1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

* lib/xmlrpc/create.rb (XMLRPC::Create::conv2value): Symbol should

come earlier than String.

* lib/soap/mapping/rubytypeFactory.rb (RubytypeFactory::obj2soap):
  ditto.

* lib/set.rb (TC_Set::test_s_new): strings are no longer
  Enumerable

* lib/soap/property.rb (Property::load): ditto.

* lib/webrick/httputils.rb (WEBrick::HTTPUtils::parse_header): ditto.

* lib/soap/mimemessage.rb (MIMEMessage::Headers::parse): ditto.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@11259 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
matz 2006-11-02 00:21:28 +00:00
parent 92ca42cb3e
commit 84e2f5268a
10 changed files with 37 additions and 21 deletions

View file

@ -129,22 +129,22 @@ module GenSupport
private
def trim_eol(str)
str.collect { |line|
str.lines.collect { |line|
line.sub(/\r?\n\z/, "") + "\n"
}.join
end
def trim_indent(str)
indent = nil
str = str.collect { |line| untab(line) }.join
str.each do |line|
str = str.lines.collect { |line| untab(line) }.join
str.each_line do |line|
head = line.index(/\S/)
if !head.nil? and (indent.nil? or head < indent)
indent = head
end
end
return str unless indent
str.collect { |line|
str.lines.collect { |line|
line.sub(/^ {0,#{indent}}/, "")
}.join
end