aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authortadf <tadf@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-09-20 22:55:59 +0000
committertadf <tadf@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-09-20 22:55:59 +0000
commit31eacb6ed129b7483f6f8a74034986cb7ead1836 (patch)
tree67f8feeae29e2940d4763306c61e0c217174fa7d
parent9467d7a02430cbe76368148fe8097d7d029e6def (diff)
downloadruby-31eacb6ed129b7483f6f8a74034986cb7ead1836.tar.gz
* lib/complex.rb: provides some obsolate methods.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@19440 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--ChangeLog2
-rw-r--r--lib/complex.rb6
2 files changed, 7 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index f00c1d8bfb..adb8309648 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -15,7 +15,7 @@ Sun Sep 21 07:43:16 2008 Tadayoshi Funaba <tadf@dotrb.org>
* lib/mathn.rb: ditto.
- * lib/complex.rb: ditto.
+ * lib/complex.rb: ditto. and provides some obsolate methods.
Sun Sep 21 02:48:45 2008 NARUSE, Yui <naruse@ruby-lang.org>
diff --git a/lib/complex.rb b/lib/complex.rb
index c03ee63c3e..301879143f 100644
--- a/lib/complex.rb
+++ b/lib/complex.rb
@@ -16,3 +16,9 @@ class Complex
alias image imag
end
+
+class Numeric
+
+ def im() Complex(0, self) end
+
+end