From b3a2c7611e947e210bfa6ef10b5171aa2762191d 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] [DOC] specify the unit of return value for Date#- --- 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 63e8c61..81b3a14 100644 --- a/ext/date/date_core.c +++ b/ext/date/date_core.c @@ -6332,9 +6332,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 #=> #