1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

* time.c: rdoc fix for <=>

* array.c: ditto

* bignum.c: ditto

* compar.c: ditto

* file.c: ditto

* numeric.c: ditto

* string.c: rdoc fix for <=> and casecmp

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@25523 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
marcandre 2009-10-28 05:01:29 +00:00
parent 20a2b656c2
commit ea1b7a9577
7 changed files with 12 additions and 13 deletions

View file

@ -2823,7 +2823,7 @@ recursive_cmp(ary1, ary2, recur)
/*
* call-seq:
* array <=> other_array -> -1, 0, +1
* array <=> other_array -> -1, 0, +1 or nil
*
* Comparison---Returns an integer (-1, 0,
* or +1) if this array is less than, equal to, or greater than

View file

@ -986,7 +986,7 @@ rb_big_to_f(x)
/*
* call-seq:
* big <=> numeric => -1, 0, +1
* big <=> numeric => -1, 0, +1 or nil
*
* Comparison---Returns -1, 0, or +1 depending on whether <i>big</i> is
* less than, equal to, or greater than <i>numeric</i>. This is the

View file

@ -196,7 +196,9 @@ cmp_between(x, min, max)
* may be ordered. The class must define the <code><=></code> operator,
* which compares the receiver against another object, returning -1, 0,
* or +1 depending on whether the receiver is less than, equal to, or
* greater than the other object. <code>Comparable</code> uses
* greater than the other object. If the other object is not comparable
* then the <code><=></code> operator should return nil.
* <code>Comparable</code> uses
* <code><=></code> to implement the conventional comparison operators
* (<code><</code>, <code><=</code>, <code>==</code>, <code>>=</code>,
* and <code>></code>) and the method <code>between?</code>.

2
file.c
View file

@ -187,7 +187,7 @@ get_stat(self)
/*
* call-seq:
* stat <=> other_stat => -1, 0, 1
* stat <=> other_stat => -1, 0, +1 or nil
*
* Compares <code>File::Stat</code> objects by comparing their
* respective modification times.

View file

@ -914,7 +914,7 @@ rb_dbl_cmp(a, b)
/*
* call-seq:
* flt <=> numeric => -1, 0, +1
* flt <=> numeric => -1, 0, +1 or nil
*
* Returns -1, 0, or +1 depending on whether <i>flt</i> is less than,
* equal to, or greater than <i>numeric</i>. This is the basis for the
@ -2423,7 +2423,7 @@ fix_equal(x, y)
/*
* call-seq:
* fix <=> numeric => -1, 0, +1
* fix <=> numeric => -1, 0, +1 or nil
*
* Comparison---Returns -1, 0, or +1 depending on whether <i>fix</i> is
* less than, equal to, or greater than <i>numeric</i>. This is the

View file

@ -1031,7 +1031,7 @@ rb_str_eql(str1, str2)
/*
* call-seq:
* str <=> other_str => -1, 0, +1
* str <=> other_str => -1, 0, +1 or nil
*
* Comparison---Returns -1 if <i>other_str</i> is greater than, 0 if
* <i>other_str</i> is equal to, and +1 if <i>other_str</i> is less than
@ -1085,7 +1085,7 @@ rb_str_cmp_m(str1, str2)
/*
* call-seq:
* str.casecmp(other_str) => -1, 0, +1
* str.casecmp(other_str) => -1, 0, +1 or nil
*
* Case-insensitive version of <code>String#<=></code>.
*

7
time.c
View file

@ -950,12 +950,9 @@ time_usec(time)
/*
* call-seq:
* time <=> other_time => -1, 0, +1
* time <=> numeric => -1, 0, +1
* time <=> other_time => -1, 0, +1 or nil
*
* Comparison---Compares <i>time</i> with <i>other_time</i> or with
* <i>numeric</i>, which is the number of seconds (possibly
* fractional) since epoch.
* Comparison---Compares <i>time</i> with <i>other_time</i>.
*
* t = Time.now #=> Wed Apr 09 08:56:03 CDT 2003
* t2 = t + 2592000 #=> Fri May 09 08:56:03 CDT 2003