aboutsummaryrefslogtreecommitdiffstats
path: root/ChangeLog
Commit message (Collapse)AuthorAgeFilesLines
* optimize named capture assignmentnobu2016-03-141-0/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * compile.c (compile_named_capture_assign): optimize named capture assignments, by replacing repeating global variable accesses with `dup`, and by returning the matched result instead of re-getting it from the MatchData. * parse.y (reg_named_capture_assign_gen): build just assignment nodes for the optimization. ex. `/(?<x>.)/ =~ "bar"` - old ``` 0000 putstring "bar" 0002 opt_regexpmatch1 /(?<x>.)/ 0004 pop 0005 getglobal $~ 0007 branchunless 25 0009 getglobal $~ 0011 putobject :x 0013 opt_aref <callinfo!mid:[], argc:1, ARGS_SIMPLE> 0016 setlocal_OP__WC__0 2 0018 getglobal $~ 0020 putobject_OP_INT2FIX_O_0_C_ 0021 opt_send_without_block <callinfo!mid:begin, argc:1, ARGS_SIMPLE> 0024 leave 0025 putobject nil 0027 setlocal_OP__WC__0 2 0029 putobject nil 0031 leave ``` - new ``` 0000 putstring "bar" 0002 opt_regexpmatch1 /(?<x>.)/ 0004 getglobal $~ 0006 dup 0007 branchunless 14 0009 putobject :x 0011 opt_aref <callinfo!mid:[], argc:1, ARGS_SIMPLE> 0014 setlocal_OP__WC__0 2 0016 leave ``` git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54100 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* ruby.c: reduce fstatnobu2016-03-141-0/+8
| | | | | | | | | * file.c (ruby_is_fd_loadable): now return -1 if loadable but may block. * ruby.c (open_load_file): wait to read by the result of ruby_is_fd_loadable, without fstat. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54099 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * numeric.c (fix2str): improve r54092 like rb_int2big().naruse2016-03-141-0/+4
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54098 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* document OpenSSL::SSL::SSLContext#setup as MT-unsafenormal2016-03-141-0/+5
| | | | | | | | | | | On a cursory inspection, using rb_block_call for extra_chain_cert is thread-unsafe. There may be other instances of thread-unsafe behavior in this method, but one is enough. * ext/openssl/ossl_ssl.c (ossl_sslctx_setup): document as MT-unsafe [ruby-core:73803] [Bug #12069] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54097 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* win32.h: fix O_SHARE_DELETEnobu2016-03-131-0/+5
| | | | | | | * include/ruby/win32.h (O_SHARE_DELETE): change to fit Fixnum limit. [ruby-core:74285] [Bug #12171] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54094 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* numeric.c: fix edge casenobu2016-03-131-0/+5
| | | | | | | * numeric.c (rb_fix2str): fix edge case, accidentally generated wrong Fixnum from LONG_MIN. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54092 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Malformed RDoc syntax in catch [ci skip]nobu2016-03-121-0/+6
| | | | | | | | * vm_eval.c (rb_f_catch): [DOC] fix malformed RDoc syntax, "+...+" cannot enclose non-identifier characters. a patch by Sebastian S in [ruby-core:74278]. [Bug#12170] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54089 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * test/lib/test/unit.rb: describe !/REGEXP/ in the help message.akr2016-03-111-0/+4
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54087 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* testunit: negative filternobu2016-03-111-0/+8
| | | | | | | | | * test/lib/test/unit.rb (Options#non_options): make regexp name options prefixed with "!" negative filters. * common.mk (TEST_EXCLUDES): use negative filter to exclude memory leak tests. -x option excludes test files, not test methods. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54086 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * enc/unicode/case-folding.rb, casefold.h: Streamlining approach toduerst2016-03-111-0/+8
| | | | | | | | | | case mapping data not available from case folding by unifying all three cases (special title, special upper, special lower). * enc/unicode.c: Adjust macro names for above (macros are currently inactive). (with Kimihito Matsui) git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54085 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* iseq.h: coverage_enabled flagnobu2016-03-101-0/+10
| | | | | | | | | | * iseq.c (prepare_iseq_build): enable coverage by coverage_enabled option, not by parse_in_eval flag in the thread context. * iseq.h (rb_compile_option_struct): add coverage_enabled flag. * parse.y (yycompile0): set coverage_enabled flag if coverage array is made. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54081 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* node.c: hidden options hashnobu2016-03-101-0/+5
| | | | | | | * node.c (dump_option): nd_compile_option is a hidden hash object, cannot call inspect on it. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54077 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * test/socket/test_socket.rb (test_udp_recvmsg_truncation):odaira2016-03-101-0/+6
| | | | | | | AIX does not set the MSG_TRUNC flag for a message partially read by recvmsg(2) with the MSG_PEEK flag set. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54073 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* fix a typo [ci skip]kazu2016-03-091-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54066 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * benchmark/driver.rb: fix my last commit (syntax error).ko12016-03-091-0/+4
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54063 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * benchmark/driver.rb: fix output messages.ko12016-03-091-0/+7
| | | | | | | | * benchmark/memory_wrapper.rb: use respond_to? because member? does not work well. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54062 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * benchmark/driver.rb: support memory usage benchmark.ko12016-03-091-0/+11
| | | | | | | | | | | | | use `--measure-target=[target]'. Now, we can use the following targets: * real (default): real time which returns process time in sec. * peak: peak memory usage (physical memory) in bytes. * size: last memory usage (physical memory) in bytes. * benchmark/memory_wrapper.rb: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54060 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * benchmark/bm_vm3_gc_old_full.rb: add GC.start benchmark.ko12016-03-091-0/+8
| | | | | | | | | * benchmark/bm_vm3_gc_old_immediate.rb: ditto. * benchmark/bm_vm3_gc_old_lazy.rb: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54053 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * benchmark/driver.rb: exit benchmarking if a benchmark processko12016-03-091-0/+5
| | | | | | | receives signals. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54052 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* memory_status.rb: independent of MiniTestnobu2016-03-091-0/+8
| | | | | | | | | * test/lib/memory_status.rb: make Memory::Status independent of MiniTest::Skip. * test/lib/test/unit/assertions.rb (assert_no_memory_leak): skip if Memory::Status is not available. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54049 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * test/io/wait/test_io_wait.rb (test_wait_readwrite_timeout):odaira2016-03-091-0/+7
| | | | | | | | select(2) in AIX returns "readable" for the write-side fd of a pipe, so it is not possible to use a pipe to test the read-write timeout of IO#wait on AIX. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54047 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * test/ruby/test_require.rb (test_require_with_loaded_features_pop):headius2016-03-081-0/+5
| | | | | | Only remove PATH so threads don't accidentally double-pop. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54037 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* vm_method.c: fix aliased original namenobu2016-03-081-0/+6
| | | | | | | | * vm_method.c (rb_alias): the original name should be properly available method_added method, set the name before calling the hook. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54035 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* logger.rb: kwd argsnobu2016-03-081-0/+5
| | | | | | | * lib/logger.rb (Logger::LogDevice#initialize): define using keyword arguments. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54031 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test/ruby/test_array.rb: split permute + stack error tests out.headius2016-03-081-0/+6
| | | | | | | | * test/ruby/test_array.rb: split out the test for no stack error on large input for test_permutation, test_repeated_permutation, and test_repeated_combination, and make them all timeout:30. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54030 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * intern.h (rb_divmod): assume compilers `/` and `%` comply C99naruse2016-03-081-0/+21
| | | | | | | | | | | | | | | | | | | | | | and reduce branching. If a compiler doesn't comply, add #ifdefs. * intern.h (rb_div): added for Ruby's behavior. * intern.h (rb_mod): added for Ruby's behavior. * insns.def (opt_div): use rb_div. * insns.def (opt_mod): use rb_mod. * numeric.c (fixdivmod): removed. * numeric.c (fix_divide): use rb_div. * numeric.c (fix_mod): use rb_mod. * numeric.c (fix_divmod): use rb_divmod. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54029 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * insns.def (opt_mod): show its method name on ZeroDivisionError.naruse2016-03-081-0/+5
| | | | | | [Bug #12158] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54028 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.c (rb_w32_write_console): now no need to checkusa2016-03-081-0/+5
| | | | | | | ERROR_CALL_NOT_IMPLEMENTED because it is for old Win9X. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54027 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * win32/win32.c (rb_w32_write_console): stop the VT100 emulation if theusa2016-03-081-0/+5
| | | | | | | console supports it natively. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54026 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * test/net/imap/test_imap.rb (test_idle_timeout): Because of theodaira2016-03-071-0/+8
| | | | | | | | | timeout specified in "imap.idle(0.2)", there is no gurantee that the server thread has done all the work before the client thread performs the assertions. It depends on the thread scheduling. Add checks to avoid false positives (on AIX, particularly). git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54025 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ruby.c (warn_cr_in_shebang): meaningless check on DOSISH platforms.usa2016-03-071-0/+5
| | | | | | | fixed a test failure introduced at r53998. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54023 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tk/lib/tkextlib/tcllib/tablelist_tile.rb: fix method name typo.nagachika2016-03-071-0/+6
| | | | | | [ruby-core:72513] [Bug #11893] The patch provided by Akira Matsuda. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54022 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tk/lib/tkextlib/tcllib/toolbar.rb: fix method name typo.nagachika2016-03-071-1/+7
| | | | | | [ruby-core:72511] [Bug #11891] The patch provided by Akira Matsuda. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54021 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tk/lib/tkextlib/blt/tree.rb: fix method name typo.nagachika2016-03-071-0/+6
| | | | | | [ruby-core:72510] [Bug #11890] The patch provided by Akira Matsuda. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54020 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/tk/lib/tk/menubar.rb: fix a typo in font name. [ruby-core:72505]nagachika2016-03-071-0/+7
| | | | | | | | [Bug #11886] The patch provided by Akira Matsuda. * ext/tk/sample/*.rb: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54018 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* class.c: err if superclass is 0nobu2016-03-071-0/+6
| | | | | | | | * class.c (rb_define_class, rb_define_class_id_under): raise ArgumentError if super is 0, deprecated behavior which has been warned long time. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54015 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* internal.h: functions for class internalsnobu2016-03-071-0/+5
| | | | | | | * internal.h: move function declarations for class internals from include/ruby/intern.h. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54014 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* win32ole_event.c: use rb_write_error_strnobu2016-03-071-0/+8
| | | | | | | | | * ext/win32ole/win32ole_event.c (rescue_callback): use rb_write_error_str instead of rb_write_error, to respect the encoding and prevent the message from GC. * internal.h (rb_write_error_str): export. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54013 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * test/ruby/test_process.rb (test_execopts_gid): Skip a testodaira2016-03-061-0/+7
| | | | | | | | that is known to fail on AIX. AIX allows setgid to a supplementary group, but Ruby does not allow the "-e" option when setgid'ed, so the test does not work as intended. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54010 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* io.c: fix output of Array [ci skip]nobu2016-03-061-0/+5
| | | | | | | * io.c (rb_obj_display): [DOC] fix output of Array, as Array#to_s is same as Array#inspect since 1.9. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54009 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * test/socket/test_addrinfo.rb (test_ipv6_address_predicates):odaira2016-03-051-0/+6
| | | | | | | IN6_IS_ADDR_V4COMPAT and IN6_IS_ADDR_V4MAPPED are broken on AIX, so skip related tests. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54005 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Sat Mar 5 09:17:54 2016 Rei Odaira <Rei.Odaira@gmail.com>odaira2016-03-051-0/+12
| | | | | | | | | | | | | | * test/rinda/test_rinda.rb (test_make_socket_ipv4_multicast): The fifth argument to getsockopt(2) should be modified to indicate the actual size of the value on return, but not in AIX. This is a know bug. Skip related tests. * test/rinda/test_rinda.rb (test_ring_server_ipv4_multicast): ditto. * test/rinda/test_rinda.rb (test_make_socket_unicast): ditto. * test/socket/test_basicsocket.rb (test_getsockopt): ditto. * test/socket/test_sockopt.rb (test_bool): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54004 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * test/-ext-/float/test_nextafter.rb: In AIX,odaira2016-03-041-0/+7
| | | | | | | | nextafter(+0.0,-0.0)=+0.0, and nextafter(-0.0,+0.0)=-0.0, but they should return -0.0 and +0.0, respectively. This is a known bug in nextafter(3) on AIX, so skip related tests. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54003 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * test/zlib/test_zlib.rb (test_adler32_combine, test_crc32_combine):odaira2016-03-041-0/+7
| | | | | | | | Skip two tests on AIX because zconf.h in zlib does not correctly recognize _LARGE_FILES in AIX. The problem was already reported to zlib, and skip these tests until it is fixed. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54002 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * thread_pthread.c (getstack): __pi_stacksize returned byodaira2016-03-041-0/+6
| | | | | | | pthread_getthrds_np() is wrong on AIX. Use __pi_stackend - __pi_stackaddr instead. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54000 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * gc.c: use 2 bits with unsigned int for rb_objspace::flags::modeko12016-03-041-0/+5
| | | | | | | because it always returns 0 to 2 (non-negative value). git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53997 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * gc.c: rename "enum gc_stat" to "enum gc_mode"ko12016-03-041-0/+18
| | | | | | | | | | | | | | | | | | | | because there is a same name (no related) function gc_stat(). Also gc_stat_* are renamed to gc_mode_*, gc_stat_transition() to gc_mode_transition(), rb_objspace::flags::stat is renamed to rb_objspace::flags::mode. Change rb_objspace::flags::mode from 2 bits to 3 bits because VC++ returns negative enum value with 2 bits. * gc.c (gc_mode): add a macro to access rb_objspace::flags::mode with verification code (verification is enabled only on RGENGC_CHECK_MODE > 0). * gc.c (gc_mode_set): same macro for setter. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53996 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/rubygems.rb, lib/rubygems/*, test/rubygems/*: Update rubygems-2.6.1.hsbt2016-03-041-0/+7
| | | | | | | | Please see entries of 2.6.0 and 2.6.1 on https://github.com/rubygems/rubygems/blob/master/History.txt [fix GH-1270] Patch by @segiddins git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53992 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* ostruct.rb: make internal methods privatenobu2016-03-031-0/+6
| | | | | | | | * lib/ostruct.rb (modifiable?, new_ostruct_member!, table!): rename methods for internal use with suffixes and make private, [ruby-core:71069] [Bug #11587] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53987 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* vm_eval.c: call method_missing by method entrynobu2016-03-021-1/+4
| | | | | | | * vm_eval.c (method_missing): call by found method entry and get rid of searching the same method entry twice. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53984 b2dd03c8-39d4-4d8f-98ff-823fe69b080e