diff --git a/object.c b/object.c index aaa3326ebf..ed7e0ff224 100644 --- a/object.c +++ b/object.c @@ -162,7 +162,7 @@ rb_obj_setup(VALUE obj, VALUE klass, VALUE type) * * Returns +true+ or +false+. * - * Like Object#==, if +object+ is an instance of Object + * Like Object#==, if +other+ is an instance of \Object * (and not an instance of one of its many subclasses). * * This method is commonly overridden by those subclasses, @@ -1892,11 +1892,12 @@ rb_mod_freeze(VALUE mod) /* * call-seq: - * mod === obj -> true or false + * self === other -> true or false * - * Case Equality---Returns true if obj is an - * instance of mod or an instance of one of mod's descendants. - * Of limited use for modules, but can be used in case statements + * Returns whether +other+ is an instance of +self+, + * or is an instance of a subclass of +self+. + * + * Of limited use for modules, but can be used in +case+ statements * to classify objects by class. */ diff --git a/range.c b/range.c index 7aa917bc06..c8a4b9938b 100644 --- a/range.c +++ b/range.c @@ -2054,10 +2054,9 @@ VALUE rb_str_include_range_p(VALUE beg, VALUE end, VALUE val, VALUE exclusive); /* * call-seq: - * self === object -> true or false + * self === other -> true or false * - * Returns +true+ if +object+ is between self.begin and self.end. - * +false+ otherwise: + * Returns whether +other+ is between self.begin and self.end: * * (1..4) === 2 # => true * (1..4) === 5 # => false diff --git a/re.c b/re.c index 621af13cd7..f8672d1d7c 100644 --- a/re.c +++ b/re.c @@ -3728,9 +3728,9 @@ rb_reg_match(VALUE re, VALUE str) /* * call-seq: - * regexp === string -> true or false + * self === other -> true or false * - * Returns +true+ if +self+ finds a match in +string+: + * Returns whether +self+ finds a match in +other+: * * /^[a-z]*$/ === 'HELLO' # => false * /^[A-Z]*$/ === 'HELLO' # => true