diff options
author | shyouhei <shyouhei@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2014-06-23 04:41:27 +0000 |
---|---|---|
committer | shyouhei <shyouhei@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2014-06-23 04:41:27 +0000 |
commit | 62bfc4f24e6cddda37461347e884c094080259ea (patch) | |
tree | f270eb17e619fac0d1bce7b757df2ce07e07c824 /complex.c | |
parent | 6adcf6a898cd8d6becfebd0ee1a881e9bc77c3be (diff) | |
download | ruby-62bfc4f24e6cddda37461347e884c094080259ea.tar.gz |
* include/ruby/ruby.h (struct RComplex): no longer. [Feature #9888]
* include/ruby/ruby.h (RCOMPLEX): ditto.
* include/ruby/ruby.h (RCOMPLEX_SET_REAL): deprecated. Will be deleted later.
* include/ruby/ruby.h (RCOMPLEX_SET_IMAG): ditto.
* internal.h (struct RFloat): moved here.
* internal.h (RCOMPLEX): ditto.
* complex.c (rb_complex_set_real): do not use this.
* complex.c (rb_complex_set_imag): ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46506 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'complex.c')
-rw-r--r-- | complex.c | 14 |
1 files changed, 14 insertions, 0 deletions
@@ -1342,6 +1342,20 @@ rb_Complex(VALUE x, VALUE y) return nucomp_s_convert(2, a, rb_cComplex); } +VALUE +rb_complex_set_real(VALUE cmp, VALUE r) +{ + RCOMPLEX_SET_REAL(cmp, r); + return cmp; +} + +VALUE +rb_complex_set_imag(VALUE cmp, VALUE i) +{ + RCOMPLEX_SET_REAL(cmp, i); + return cmp; +} + /* * call-seq: * cmp.to_i -> integer |