summaryrefslogtreecommitdiff
path: root/sample
diff options
context:
space:
mode:
authortadf <tadf@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2003-05-05 14:02:14 +0000
committertadf <tadf@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2003-05-05 14:02:14 +0000
commit6154ce97a7915ac70326c007ee04a22fe5742e04 (patch)
tree8e1943ac59519bd7f142e72dfbfc88880ed69656 /sample
parentb65e3629dad9fba8f37202d3dc0103d9d08c1396 (diff)
use values_at instead of select.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3757 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'sample')
-rw-r--r--sample/biorhythm.rb2
-rw-r--r--sample/cal.rb2
2 files changed, 2 insertions, 2 deletions
diff --git a/sample/biorhythm.rb b/sample/biorhythm.rb
index 74e615a..c7e26c4 100644
--- a/sample/biorhythm.rb
+++ b/sample/biorhythm.rb
@@ -59,7 +59,7 @@ def getPosition(z)
end
def parsedate(s)
- ParseDate::parsedate(s).select(0, 1, 2)
+ ParseDate::parsedate(s).values_at(0, 1, 2)
end
def name_of_week(date)
diff --git a/sample/cal.rb b/sample/cal.rb
index 0b2d921..e845234 100644
--- a/sample/cal.rb
+++ b/sample/cal.rb
@@ -84,7 +84,7 @@ end
usage unless getopts('jmty', "c:#{$cc}")
-y, m = ARGV.select(1, 0).compact.collect{|x| x.to_i}
+y, m = ARGV.values_at(1, 0).compact.collect{|x| x.to_i}
$OPT_y ||= (y and not m)
to = Date.today