summaryrefslogtreecommitdiff
path: root/golf_prelude.rb
diff options
context:
space:
mode:
authorusa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2007-12-27 16:47:58 (GMT)
committerusa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2007-12-27 16:47:58 (GMT)
commitb8f8c75579c31ef11697ff52dfe72a35d8bb5e9b (patch)
treea4c14a15590570537bfae9bcd101c4541c9dd702 /golf_prelude.rb
parent7ee205d1d1b273fa660ff35ce08544d5c3a3b9df (diff)
* golf_prelude.rb (Integer): Integer is now enumerable on goruby.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14745 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'golf_prelude.rb')
-rw-r--r--golf_prelude.rb8
1 files changed, 8 insertions, 0 deletions
diff --git a/golf_prelude.rb b/golf_prelude.rb
index a4b2753..602767a 100644
--- a/golf_prelude.rb
+++ b/golf_prelude.rb
@@ -9,3 +9,11 @@ class Object
puts "#{a}ello, #{b}orld#{c}"
end
end
+
+class Integer
+ def each(&b)
+ times &b
+ end
+
+ include Enumerable
+end