diff options
author | p0pemaru <[email protected]> | 2023-08-14 21:40:21 +0900 |
---|---|---|
committer | git <[email protected]> | 2024-06-03 05:24:18 +0000 |
commit | cb6dcc77460272f56e2bd62874a9ea4c34ac5f33 (patch) | |
tree | 8907e16a0eb1db49ac1a65a20eea8548a7481371 /ext/date/date_core.c | |
parent | 77e5e06846ffac01459fe18e9e293b6e5ebb3d4e (diff) |
[ruby/date] [DOC] specify the unit of return value for Date#-
https://github.com/ruby/date/commit/b3a2c7611e
Diffstat (limited to 'ext/date/date_core.c')
-rw-r--r-- | ext/date/date_core.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/ext/date/date_core.c b/ext/date/date_core.c index b2b11e7d63..ca9449f0e9 100644 --- a/ext/date/date_core.c +++ b/ext/date/date_core.c @@ -6326,9 +6326,11 @@ minus_dd(VALUE self, VALUE other) * call-seq: * d - other -> date or rational * - * Returns the difference between the two dates if the other is a date - * object. If the other is a numeric value, returns a date object - * pointing +other+ days before self. If the other is a fractional number, + * If the other is a date object, returns a Rational + * whose value is the difference between the two dates in days. + * If the other is a numeric value, returns a date object + * pointing +other+ days before self. + * If the other is a fractional number, * assumes its precision is at most nanosecond. * * Date.new(2001,2,3) - 1 #=> #<Date: 2001-02-02 ...> |