summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornagachika <nagachika@ruby-lang.org>2021-12-24 14:35:34 +0900
committernagachika <nagachika@ruby-lang.org>2021-12-24 14:35:34 +0900
commitbadffc7bee32251e2bea5897dc502b887e7ffa9b (patch)
tree305d4cb1df7a51229b215e7d08a3d538c01432fb
parent69272c74a3f675373fc6c6f32b685620da8a85ee (diff)
merge revision(s) 7f4e86804d426d79807cc038fe4444f7c65f5c4a: [Backport #18163]
Fix documentation of #<=> and #casecmp [ci skip] Descriptions for return values of -1 and 1 were reversed. --- string.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
-rw-r--r--string.c8
-rw-r--r--version.h4
2 files changed, 6 insertions, 6 deletions
diff --git a/string.c b/string.c
index 7fb45c1f72..1db7acc8c8 100644
--- a/string.c
+++ b/string.c
@@ -3454,9 +3454,9 @@ rb_str_eql(VALUE str1, VALUE str2)
* string <=> other_string -> -1, 0, 1, or nil
*
* Compares +self+ and +other_string+, returning:
- * - -1 if +other_string+ is smaller.
+ * - -1 if +other_string+ is larger.
* - 0 if the two are equal.
- * - 1 if +other_string+ is larger.
+ * - 1 if +other_string+ is smaller.
* - +nil+ if the two are incomparable.
*
* Examples:
@@ -3488,9 +3488,9 @@ static VALUE str_casecmp_p(VALUE str1, VALUE str2);
* str.casecmp(other_str) -> -1, 0, 1, or nil
*
* Compares +self+ and +other_string+, ignoring case, and returning:
- * - -1 if +other_string+ is smaller.
+ * - -1 if +other_string+ is larger.
* - 0 if the two are equal.
- * - 1 if +other_string+ is larger.
+ * - 1 if +other_string+ is smaller.
* - +nil+ if the two are incomparable.
*
* Examples:
diff --git a/version.h b/version.h
index 1cdc1f413f..6903a7c682 100644
--- a/version.h
+++ b/version.h
@@ -12,11 +12,11 @@
# define RUBY_VERSION_MINOR RUBY_API_VERSION_MINOR
#define RUBY_VERSION_TEENY 4
#define RUBY_RELEASE_DATE RUBY_RELEASE_YEAR_STR"-"RUBY_RELEASE_MONTH_STR"-"RUBY_RELEASE_DAY_STR
-#define RUBY_PATCHLEVEL 160
+#define RUBY_PATCHLEVEL 161
#define RUBY_RELEASE_YEAR 2021
#define RUBY_RELEASE_MONTH 12
-#define RUBY_RELEASE_DAY 2
+#define RUBY_RELEASE_DAY 24
#include "ruby/version.h"