Feature #10755 ยป using_rb_define_method_for_rbHash.patch
hash.c | ||
---|---|---|
rb_define_method(rb_cHash,"eql?", rb_hash_eql, 1);
|
||
rb_define_method(rb_cHash,"fetch", rb_hash_fetch_m, -1);
|
||
rb_define_method(rb_cHash,"[]=", rb_hash_aset, 2);
|
||
rb_define_method(rb_cHash,"store", rb_hash_aset, 2);
|
||
rb_define_alias(rb_cHash,"store", "[]=");
|
||
rb_define_method(rb_cHash,"default", rb_hash_default, -1);
|
||
rb_define_method(rb_cHash,"default=", rb_hash_set_default, 1);
|
||
rb_define_method(rb_cHash,"default_proc", rb_hash_default_proc, 0);
|
||
... | ... | |
rb_define_method(rb_cHash,"key", rb_hash_key, 1);
|
||
rb_define_method(rb_cHash,"index", rb_hash_index, 1);
|
||
rb_define_method(rb_cHash,"size", rb_hash_size, 0);
|
||
rb_define_method(rb_cHash,"length", rb_hash_size, 0);
|
||
rb_define_alias(rb_cHash,"length", "size");
|
||
rb_define_method(rb_cHash,"empty?", rb_hash_empty_p, 0);
|
||
rb_define_method(rb_cHash,"each_value", rb_hash_each_value, 0);
|
||
rb_define_method(rb_cHash,"each_key", rb_hash_each_key, 0);
|
||
rb_define_method(rb_cHash,"each_pair", rb_hash_each_pair, 0);
|
||
rb_define_method(rb_cHash,"each", rb_hash_each_pair, 0);
|
||
rb_define_alias(rb_cHash,"each", "each_pair");
|
||
rb_define_method(rb_cHash,"keys", rb_hash_keys, 0);
|
||
rb_define_method(rb_cHash,"values", rb_hash_values, 0);
|
||
... | ... | |
rb_define_method(rb_cHash,"invert", rb_hash_invert, 0);
|
||
rb_define_method(rb_cHash,"update", rb_hash_update, 1);
|
||
rb_define_alias(rb_cHash,"merge!", "update");
|
||
rb_define_method(rb_cHash,"replace", rb_hash_replace, 1);
|
||
rb_define_method(rb_cHash,"merge!", rb_hash_update, 1);
|
||
rb_define_method(rb_cHash,"merge", rb_hash_merge, 1);
|
||
rb_define_method(rb_cHash, "assoc", rb_hash_assoc, 1);
|
||
rb_define_method(rb_cHash, "rassoc", rb_hash_rassoc, 1);
|
||
rb_define_method(rb_cHash, "flatten", rb_hash_flatten, -1);
|
||
rb_define_method(rb_cHash,"include?", rb_hash_has_key, 1);
|
||
rb_define_method(rb_cHash,"member?", rb_hash_has_key, 1);
|
||
rb_define_method(rb_cHash,"has_key?", rb_hash_has_key, 1);
|
||
rb_define_method(rb_cHash,"has_value?", rb_hash_has_value, 1);
|
||
rb_define_method(rb_cHash,"key?", rb_hash_has_key, 1);
|
||
rb_define_method(rb_cHash,"value?", rb_hash_has_value, 1);
|
||
rb_define_method(rb_cHash, "has_key?", rb_hash_has_key, 1);
|
||
rb_define_alias(rb_cHash, "include?", "has_key?");
|
||
rb_define_alias(rb_cHash, "member?", "has_key?");
|
||
rb_define_alias(rb_cHash, "key?", "has_key?");
|
||
rb_define_method(rb_cHash, "has_value?", rb_hash_has_value, 1);
|
||
rb_define_alias(rb_cHash, "value?", "has_value?");
|
||
rb_define_method(rb_cHash,"compare_by_identity", rb_hash_compare_by_id, 0);
|
||
rb_define_method(rb_cHash,"compare_by_identity?", rb_hash_compare_by_id_p, 0);
|
||
-
|