From f550e69efc38c659575e0bca179475ddb714cddd Mon Sep 17 00:00:00 2001 From: matz Date: Tue, 22 Apr 2003 08:18:19 +0000 Subject: * parse.y (arg_ambiguous): hopefully better message. * lib/cgi.rb (CGI::QueryExtension::initialize_query): to_ary git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3711 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- lib/rational.rb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'lib/rational.rb') diff --git a/lib/rational.rb b/lib/rational.rb index e63e8c4814..0c784fb94b 100644 --- a/lib/rational.rb +++ b/lib/rational.rb @@ -67,7 +67,9 @@ class Rational < Numeric def Rational.new!(num, den = 1) new(num, den) end - + + private_class_method :new + def initialize(num, den) if den < 0 num = -num -- cgit v1.2.3