[前][次][番号順一覧][スレッド一覧]

ruby-changes:18274

From: tenderlove <ko1@a...>
Date: Thu, 23 Dec 2010 08:27:20 +0900 (JST)
Subject: [ruby-changes:18274] Ruby:r30297 (trunk): passing nil to split is not necessary

tenderlove	2010-12-23 08:18:05 +0900 (Thu, 23 Dec 2010)

  New Revision: 30297

  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=30297

  Log:
    passing nil to split is not necessary

  Modified files:
    trunk/lib/net/smtp.rb

Index: lib/net/smtp.rb
===================================================================
--- lib/net/smtp.rb	(revision 30296)
+++ lib/net/smtp.rb	(revision 30297)
@@ -1004,7 +1004,7 @@
         return {} unless @string[3, 1] == '-'
         h = {}
         @string.lines.drop(1).each do |line|
-          k, *v = line[4..-1].chomp.split(nil)
+          k, *v = line[4..-1].chomp.split
           h[k] = v
         end
         h

--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]