From cb6dcc77460272f56e2bd62874a9ea4c34ac5f33 Mon Sep 17 00:00:00 2001 From: p0pemaru <36598331+p0pemaru@users.noreply.github.com> Date: Mon, 14 Aug 2023 21:40:21 +0900 Subject: [PATCH] [ruby/date] [DOC] specify the unit of return value for Date#- https://github.com/ruby/date/commit/b3a2c7611e --- ext/date/date_core.c | 8 +++++--- 1 file 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 #=> #