* ext/stringio/stringio.c (strio_ungetbyte): pad with \000 when
the current position is after the end.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53181 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test/stringio/test_stringio.rb (test_ungetc_pos): add a test for
r26588.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53180 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
should check whether a newly created method override a optimize
method in case the method is defined in a prepended module of a
built-in class.
[ruby-core:72226] [Bug #11836]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53179 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
class instead of the origin iclass.
[ruby-core:72188] [Bug #11826]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53173 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* string.c (rb_str_scrub): the result should be infected by the
original string.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53169 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* transcode.c (rb_econv_substr_append, econv_primitive_convert):
the result should be infected by the original string.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53168 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
with keyword arguments for VM_METHOD_TYPE_ATTRSET type methods.
Normally, we can not use keyword arguments for this kind of methods,
(obj.foo = 1), but we can set alias names for them.
[Bug #11657]
* test/ruby/test_keyword.rb: add a test for this fix.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53164 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Patch provided by tenderlove and nobu.
* test/fiddle/test_handle.rb (class TestHandle): add test for above.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53153 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
[Bug #11750]
* vm.c (vm_make_proc_from_block): should return a Proc object
if block is given. Previous implementation returns
a Proc object only when corresponding Proc object is not
available.
* vm.c (vm_make_env_each): ditto.
* test/ruby/test_proc.rb: add a test for this bug.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53144 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
When you change this to true, you may need to add more tests.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53141 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test/ruby/test_io.rb (test_advise_pipe): ignore not-implemented
fadvice(2) when it is present but not implemented, as IO#advice
does nothing and raises no exceptions. [Feature #11806]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53139 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
At the point where q.size == 0, we can't know that num_threads
threads have actually finished. On e.g. JRuby, they may have
called pop but not yet exited the Thread's body.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53137 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
TimeoutMutex only when accessing @timeout_info for avoiding
potential deadlock. [Bug #11742] [ruby-dev:49387]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53134 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
TimeoutMutex should be acquired when accessing @timeout_info.
To avoid deadlock, interrupt() calls are delayed.
Due to the mutex, it is safe to treat ary without ary.dup.
[Bug #11742] [ruby-dev:49387]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53130 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Suppress "syntax error: empty declaration" warnings by
Oracle Solaris Studio 12.x on Solaris. [Bug #11821]
* hash.c: ditto, after NOINSERT_UPDATE_CALLBACK().
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53129 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
test/ruby/test_transcode.rb: Fixed encoding name
to the correct one in the IANA registry (IBM037)
and added an alias (ebcdic-cp-us)
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53124 b2dd03c8-39d4-4d8f-98ff-823fe69b080e