summaryrefslogtreecommitdiff
path: root/object.c
AgeCommit message (Collapse)Author
2015-01-30merge revision(s) 45375,48260,48320,48746: [Backport #10526]usa
* complax.c: [DOC] Document number conversion of `nil` by @skade [fix GH-570] [ci skip] * object.c, rational.c: ditto. * object.c: fix document of Kernel.Stirng by @suzukaze [fix GH-743][ci skip] * object.c (Module#const_defined?): [DOC] Revise the documentation. Patch by Xavier Noria. [Fixes GH-754] https://github.com/ruby/ruby/pull/754 * object.c: [DOC] Revise documentation by Marcus Stollsteimer at [ruby-core:66368]. [Bug #10526] * #inspect: be more specific about generated string, remove obsolete example. * #nil?: use code examples instead of different call-seq's. * #tap: clarify what is yielded. * Integer(): be more specific about to_int and to_i, remove reference to Ruby 1.8. * Array(): fix error. * Class: fix variable name style and indentation in example. * improve consistency, fix typos and formatting. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_0_0@49448 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-09-12merge revision(s) 46501,47372,47460: [Backport #10191]usa
* object.c (rb_obj_copy_ivar): extract function to copy instance variables only for T_OBJECT from init_copy. * object.c (rb_obj_copy_ivar): allocate no memory for empty instance variables. [ruby-core:64700] [Bug #10191] * test/ruby/test_object.rb: extend timeout. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_0_0@47548 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-05-27merge revision(s) 45564,45565,45584,45585: [Backport #9721]usa
* proc.c (rb_method_call_with_block, umethod_bind): call with IClass including the module for a module instance method. [ruby-core:61936] [Bug #9721] * vm_insnhelper.c (vm_search_super_method): allow bound UnboundMethod case. * proc.c (umethod_bind): use the ancestor iclass instead of new iclass to get rid of infinite recursion, if the defined module is already included. [ruby-core:62014] [Bug #9721] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_0_0@46157 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-02-15merge revision(s) r44758,r44759,r44760: [Backport #9466]nagachika
object.c: error message encoding * object.c (convert_type, rb_convert_type, rb_check_convert_type), (rb_to_integer): preserve class name encoding error messages. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_0_0@44987 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-09-13merge revision(s) 42541: [Backport #8903]nagachika
* object.c (Init_Object): undef Module#prepend_features on Class, as well as Module#append_features. [Fixes GH-376] * test_class.rb: Added test for above. And ensure type checking on similar methods as module_function. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_0_0@42936 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-09-11merge revision(s) 40021,42380: [Backport #8686]nagachika
test_method.rb: split * test/ruby/test_method.rb (test_define_method): split for each tests. * object.c (rb_class_inherited_p): allow iclasses to be tested for inheritance. [Bug #8686] [ruby-core:56174] * test/ruby/test_method.rb: add test git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_0_0@42914 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-07-13merge revision(s) 41863:nagachika
Module extended doc by @PragTob [fixes GH-335] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_0_0@41950 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-07-13merge revision(s) 41854,41867:nagachika
* object.c: Fix rdoc for Kernel#<=>. [Fix GH-352] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_0_0@41947 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-05-04merge revision(s) 40561: [Backport #8357]nagachika
* object.c (rb_obj_is_kind_of): skip prepending modules. [ruby-core:54742] [Bug #8357] * object.c (rb_class_inherited_p): ditto. [ruby-core:54736] [Bug #8357] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_0_0@40575 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-03-26merge revision(s) 39739: [Backport #8081]nagachika
* object.c (Init_Object): remove Module#used, which has been introduced in Ruby 2.0 by mistake. [Bug #7916] [ruby-core:52719] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_0_0@39951 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-03-09merge revision(s) 39418:nagachika
* array.c: Document #<=> return values and formatting * bignum.c: ditto * file.c: ditto * object.c: ditto * numeric.c: ditto * rational.c: ditto * string.c: ditto * time.c: ditto git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_0_0@39666 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-03-09merge revision(s) 39414:nagachika
* object.c (rb_obj_comp): Documenting Object#<=> return values Patch by Stefan Rusterholz git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_0_0@39663 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-02-24* object.c: Document Data class by Matthew Mongeau [Backport #7929]zzak
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_0_0@39456 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-02-24* object.c: rdoc formatting for Kernel#Array() [Backport #7931]zzak
* array.c: Add rdoc for Array() method to Creating Arrays section git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_0_0@39454 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-02-22* backport r39400-r39407 from trunk.marcandre
* NEWS: many additions * object.c: Add doc for Module.prepended git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_0_0@39409 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-29* object.c: Improve error for failed implicit conversions [Bug #7539]marcandre
* error.c: Adapt rdoc * test/ruby/test_object.rb: Test for above git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38979 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-29* object.c: Fix rdoc typo, patch by Narsimham Chelluri [#7753].marcandre
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38976 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-17* object.c: Typo in Kernel#hash documentation.eregon
Patch by zed_0xff [Github Fixes #237] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38862 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-15object.c: CLASS_OR_MODULE_Pnobu
* object.c (rb_mod_to_s, rb_class_inherited_p, rb_mod_ge, rb_mod_cmp): use BUILTIN_TYPE() instead of TYPE() for optimization. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38838 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2013-01-15object.c: two literalsnobu
* object.c (rb_mod_to_s): concatenate two literals. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38837 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-12-29object.c: singleton class clonenobu
* object.c (rb_obj_clone): attach clone to its singleton class during cloning singleton class so that singleton_method_added will be called on it. based on the patch by shiba (satoshi shiba)[Bug #5283] in [ruby-dev:44477]. [Bug #5283] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38648 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-12-22internal.h: quote unprintablenobu
* internal.h (QUOTE, QUOTE_ID): quote unprintable chars in strings and IDs. [Bug #7574] [ruby-dev:46749] * string.c (rb_str_quote_unprintable): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38558 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-12-22object.c: no nested symbolnobu
* object.c (rb_mod_const_get): symbol cannot be nested constant name. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38553 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-12-22object.c: defer creating stringnobu
* object.c (rb_mod_const_get): defer creating partinal name string until needed. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38552 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-12-22object.c: check more strictlynobu
* object.c (rb_mod_const_get): check more strictly. [ruby-dev:46748] [Bug #7573] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38551 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-12-21* object.c (rb_obj_hash): shouldn't assume object_id can be long.usa
based on a patch by Heesob Park at [ruby-core:51060]. cf. [Backport #7454] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38539 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-12-19object.c: nul in const namenobu
* object.c (rb_mod_const_get): nul byte is invalid as constant name. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38466 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-12-13* object.c (Init_Object): no needs to override with same method.nobu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38366 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-12-13 * object.c (Init_Object): use rb_mod_init_copy for Class#initialize_copycharliesome
* class.c (rb_class_init_copy): rename to class_init_copy_check, performs type checks on arguments to prevent reinitialization of initialized class [ruby-core:50869] [Bug #7557] * class.c (rb_mod_init_copy): use class_init_copy_check if receiver is T_CLASS * test/ruby/test_class.rb (class TestClass): related test git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38364 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-12-06* revised r37993 to avoid SEGV/ILL in tests. In r37993, a methodshugo
entry with VM_METHOD_TYPE_REFINED holds only the original method definition, so ci->me is set to a method entry allocated in the stack, and it causes SEGV/ILL. In this commit, a method entry with VM_METHOD_TYPE_REFINED holds the whole original method entry. Furthermore, rb_thread_mark() is changed to mark cfp->klass to avoid GC for iclasses created by copy_refinement_iclass(). * vm_method.c (rb_method_entry_make): add a method entry with VM_METHOD_TYPE_REFINED to the class refined by the refinement if the target module is a refinement. When a method entry with VM_METHOD_TYPE_UNDEF is invoked by vm_call_method(), a method with the same name is searched in refinements. If such a method is found, the method is invoked. Otherwise, the original method in the refined class (rb_method_definition_t::body.orig_me) is invoked. This change is made to simplify the normal method lookup and to improve the performance of normal method calls. * vm_method.c (EXPR1, search_method, rb_method_entry), vm_eval.c (rb_call0, rb_search_method_entry): do not use refinements for method lookup. * vm_insnhelper.c (vm_call_method): search methods in refinements if ci->me is VM_METHOD_TYPE_REFINED. If the method is called by super (i.e., ci->call == vm_call_super_method), skip the same method entry as the current method to avoid infinite call of the same method. * class.c (include_modules_at): add a refined method entry for each method defined in a module included in a refinement. * class.c (rb_prepend_module): set an empty table to RCLASS_M_TBL(klass) to add refined method entries, because refinements should have priority over prepended modules. * proc.c (mnew): use rb_method_entry_with_refinements() to get a refined method. * vm.c (rb_thread_mark): mark cfp->klass for iclasses created by copy_refinement_iclass(). * vm.c (Init_VM), cont.c (fiber_init): initialize th->cfp->klass. * test/ruby/test_refinement.rb (test_inline_method_cache): do not skip the test because it should pass successfully. * test/ruby/test_refinement.rb (test_redefine_refined_method): new test for the case a refined method is redefined. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38236 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-12-03object.c: test bits at oncenobu
* object.c (rb_obj_clone): test TAINT and UNTRUSTED bits at once. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38158 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-12-01object.c: make remove_instance_variable publicnobu
* object.c (Init_Object): make remove_instance_variable public. [Feature #6539] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38114 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-11-30* revert r37993 to avoid SEGV in tests.shugo
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38022 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-11-29* vm_method.c (rb_method_entry_make): add a method entry withshugo
VM_METHOD_TYPE_REFINED to the class refined by the refinement if the target module is a refinement. When a method entry with VM_METHOD_TYPE_UNDEF is invoked by vm_call_method(), a method with the same name is searched in refinements. If such a method is found, the method is invoked. Otherwise, the original method in the refined class (rb_method_definition_t::body.orig_def) is invoked. This change is made to simplify the normal method lookup and to improve the performance of normal method calls. * vm_method.c (EXPR1, search_method, rb_method_entry), vm_eval.c (rb_call0, rb_search_method_entry): do not use refinements for method lookup. * vm_insnhelper.c (vm_call_method): search methods in refinements if ci->me is VM_METHOD_TYPE_REFINED. If the method is called by super (i.e., ci->call == vm_call_super_method), skip the same method entry as the current method to avoid infinite call of the same method. * class.c (include_modules_at): add a refined method entry for each method defined in a module included in a refinement. * class.c (rb_prepend_module): set an empty table to RCLASS_M_TBL(klass) to add refined method entries, because refinements should have priority over prepended modules. * proc.c (mnew): use rb_method_entry_with_refinements() to get a refined method. * test/ruby/test_refinement.rb (test_inline_method_cache): do not skip the test because it should pass successfully. * test/ruby/test_refinement.rb (test_redefine_refined_method): new test for the case a refined method is redefined. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@37993 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-11-16object.c: suppress warningnobu
* object.c (rb_obj_alloc): suppress unused variable warning. * tool/gen_dummy_probes.rb: define dtrace disabling macro. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@37691 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-11-16adjust indentnobu
* object.c (rb_obj_alloc): adjust indent. * vm.c (vm_collect_usage_{insn,operand,register}): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@37689 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-11-12* probes.d: add DTrace probe declarations. [ruby-core:27448]tenderlove
* array.c (empty_ary_alloc, ary_new): added array create DTrace probe. * compile.c (rb_insns_name): allowing DTrace probes to access instruction sequence name. * Makefile.in: translate probes.d file to appropriate header file. * common.mk: declare dependencies on the DTrace header. * configure.in: add a test for existence of DTrace. * eval.c (setup_exception): add a probe for when an exception is raised. * gc.c: Add DTrace probes for mark begin and end, and sweep begin and end. * hash.c (empty_hash_alloc): Add a probe for hash allocation. * insns.def: Add probes for function entry and return. * internal.h: function declaration for compile.c change. * load.c (rb_f_load): add probes for `load` entry and exit, require entry and exit, and wrapping search_required for load path search. * object.c (rb_obj_alloc): added a probe for general object creation. * parse.y (yycompile0): added a probe around parse and compile phase. * string.c (empty_str_alloc, str_new): DTrace probes for string allocation. * test/dtrace/*: tests for DTrace probes. * vm.c (vm_invoke_proc): add probes for function return on exception raise, hash create, and instruction sequence execution. * vm_core.h: add probe declarations for function entry and exit. * vm_dump.c: add probes header file. * vm_eval.c (vm_call0_cfunc, vm_call0_cfunc_with_frame): add probe on function entry and return. * vm_exec.c: expose instruction number to instruction name function. * vm_insnshelper.c: add function entry and exit probes for cfunc methods. * vm_insnhelper.h: vm usage information is always collected, so uncomment the functions. 12 19:14:50 2012 Akinori MUSHA <knu@iDaemons.org> * configure.in (isinf, isnan): isinf() and isnan() are macros on DragonFly which cannot be found by AC_REPLACE_FUNCS(). This workaround enforces the fact that they exist on DragonFly. 12 15:59:38 2012 Shugo Maeda <shugo@ruby-lang.org> * vm_core.h (rb_call_info_t::refinements), compile.c (new_callinfo), vm_insnhelper.c (vm_search_method): revert r37616 because it's too slow. [ruby-dev:46477] * test/ruby/test_refinement.rb (test_inline_method_cache): skip the test until the bug is fixed efficiently. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@37631 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-11-07object.c: inadvertent symbolnobu
* object.c (rb_mod_const_get): avoid inadvertent symbol creation. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@37532 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-11-06* object.c (rb_mod_const_get): Fix constant missing exception classtenderlove
and message to maintain backwards compatibility. Constant search should start at Object when constant starts with '::' * test/ruby/test_module.rb: test for fixes git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@37494 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-11-02* object.c (rb_mod_to_s): Module#{to_s,inspect}, when invoked onshugo
a refinement, returns a string in the format #<refinement:C@M>, where C is a refined class and M is a module at which the refinemet is defined. * eval.c (rb_mod_refine): store information on a refinement for the above change. * test/ruby/test_refinement.rb: related test. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@37424 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-10-27* object.c (rb_mod_const_get): make sure the constant name istenderlove
converted to a string before searching. [ruby-core:48405] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@37340 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-10-26* object.c (rb_mod_const_get): const_get accepts qualified constanttenderlove
strings. e.g. Object.const_get("Foo::Bar::Baz") [ruby-core:41404] * test/ruby/test_module.rb: tests for new behavior git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@37335 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-10-20* include/ruby/ruby.h: add C APIs.nari
VALUE rb_newobj_of(VALUE klass, VALUE flags) #define NEWOBJ_OF(obj,type,klass,flags) These allow to change a allocation strategy depending on klass or flags. * gc.c: ditto * array.c: use new C API. * bignum.c: ditto * class.c: ditto * complex.c: ditto * ext/socket/ancdata.c: ditto * ext/socket/option.c: ditto * hash.c: ditto * io.c: ditto * marshal.c: ditto * numeric.c: ditto * object.c: ditto * random.c: ditto * range.c: ditto * rational.c: ditto * re.c: ditto * string.c: ditto * struct.c: ditto [Feature #7177][Feature #7047] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@37275 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-09-08internal.h: allocator function in rb_classext_tnobu
* internal.h (struct rb_classext_struct): move allocator function into rb_classext_t from ordinary method table. [ruby-dev:46121] [Feature #6993] * object.c (rb_obj_alloc): call allocator function directly. * vm_method.c (rb_define_alloc_func, rb_undef_alloc_func) (rb_get_alloc_func): use allocator function in rb_classext_t. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@36925 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-08-17object.c: preserve encodingsnobu
* object.c (rb_any_to_s, rb_obj_inspect): preserve encodings of class name and instance variable names. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@36723 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-08-16object.c: forbid uninitialized classnobu
* object.c (rb_class_initialize): forbid inheriting uninitialized class. another class tree not based on BasicObject cannot exist. [ruby-core:47148][Bug #6863] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@36714 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-08-15Kernel#inspect: improve consistency and do not call #to_s.eregon
* object.c (rb_obj_inspect): Kernel#inspect: do not call #to_s. A class can now benefit from the nice default #inspect even if it defines #to_s. Also, there is no more unexpected change in #inspect result. * NEWS: Add note about the change. * bignum.c, io.c, numeric.c, object.c, proc.c, vm.c (Init_*): Adapt internal structures (by aliasing #inspect to #to_s) so they don't rely on the removed behavior (#inspect calling overridden #to_s). * test/ruby/test_object.rb (test_inspect): add tests for Kernel#inspect. * lib/pp.rb (class PP): do not call #to_s anymore, as #inspect no more does (mame). * test/test_pp.rb (class PPInspectTest): remove related assertion (mame). [ruby-core:43238][Feature #6130] * test/drb/drbtest.rb (DRbCore#teardown, DRbAry#teardown): adapt DRb tests with the new change (shirosaki). [ruby-core:47182][Bug #6866] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@36709 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-08-15Revert r36699 and r36700. [Feature #6130]naruse
Revert "Kernel#inspect: improve consistency and do not call #to_s." Revert "update PP with recent Kernel#inspect change. Patch by Yusuke Endoh." r36699 cause test-all failure on test/drb/test_drb.rb and test/drb/test_drbssl.rb. Run test-all before commit. Moreover its ChangeLog formst is wrong: see CommitterHowto https://bugs.ruby-lang.org/projects/ruby/wiki/CommitterHowto#ChangeLog git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@36701 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-08-14Kernel#inspect: improve consistency and do not call #to_s.eregon
A class can now benefit from the nice default #inspect even if it defines #to_s. Also, there is no more unexpected change in #inspect result. Internal structures have been adapted so they don't rely on the removed behavior (#inspect calling overridden #to_s). * object.c (rb_obj_inspect): Kernel#inspect: do not call #to_s. * test/ruby/test_object.rb (test_inspect): add tests for Kernel#inspect. * bignum.c, io.c, numeric.c, object.c, proc.c, vm.c (Init_*): alias #inspect to #to_s where it was expected. [ruby-core:43238][Feature #6130] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@36699 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2012-08-02* eval.c (rb_mod_using): new method Module#using. [experimental]shugo
* eval.c (rb_mod_refine): new method Module#refine. [experimental] * eval.c (f_using): new method Kernel#using. [experimental] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@36596 b2dd03c8-39d4-4d8f-98ff-823fe69b080e