value?(p1)
public
Returns true if the given value is present for some key in hsh.
h = { "a" => 100, "b" => 200 }
h.value?(100)
h.value?(999)
Show source
static VALUE
rb_hash_has_value(VALUE hash, VALUE val)
{
VALUE data[2];
data[0] = Qfalse;
data[1] = val;
rb_hash_foreach(hash, rb_hash_search_value, (VALUE)data);
return data[0];
}