------------------------------------------------------------------------
r61247 | nagachika | 2017-12-14 22:55:00 +0900 (Thu, 14 Dec 2017) | 1 line

add tag v2_4_3
------------------------------------------------------------------------
r61245 | nagachika | 2017-12-14 22:51:34 +0900 (Thu, 14 Dec 2017) | 3 lines

merge revision(s) 61242: [Backport #14185]

	Fix a command injection vulnerability in Net::FTP.
------------------------------------------------------------------------
r61239 | nagachika | 2017-12-14 22:31:41 +0900 (Thu, 14 Dec 2017) | 69 lines

merge revision(s) 60123,60172,60189,60208,60210,60211: [Backport #14005]

	webrick: avoid unnecessary IO#sync= call

	Sockets and pipes are always created with FMODE_SYNC flag
	already set (otherwise many things would be broken).

	* lib/webrick/server.rb (accept_client): remove unnecessary
	  IO#sync= call

	webrick: do not hang acceptor on slow TLS connections

	OpenSSL::SSL::SSLSocket#accept may block indefinitely on clients
	which negotiate the TCP connection, but fail (or are slow) to
	negotiate the subsequent TLS handshake.  This prevents the
	multi-threaded WEBrick server from accepting other connections.

	Since the TLS handshake (via OpenSSL::SSL::SSLSocket#accept)
	consists of normal read/write traffic over TCP, handle it in the
	per-client thread, instead.

	Furthermore, using non-blocking accept() is useful for non-TLS
	sockets anyways because spurious wakeups are possible from
	select(2).

	* lib/webrick/server.rb (accept_client): use TCPServer#accept_nonblock
	  and remove OpenSSL::SSL::SSLSocket#accept call
	* lib/webrick/server.rb (start_thread): call OpenSSL::SSL::SSLSocket#accept
	* test/webrick/test_ssl_server.rb (test_slow_connect): new test
	  [ruby-core:83221] [Bug #14005]

	webrick: fix up r60172

	By making the socket non-blocking in r60172, TLS/SSL negotiation
	via the SSL_accept function must handle non-blocking sockets
	properly and retry on SSL_ERROR_WANT_READ/SSL_ERROR_WANT_WRITE.
	OpenSSL::SSL::SSLSocket#accept cannot do that properly with a
	non-blocking socket, so it must use non-blocking logic of
	OpenSSL::SSL::SSLSocket#accept_nonblock.

	Thanks to MSP-Greg (Greg L) for finding this.

	* lib/webrick/server.rb (start_thread): use SSL_accept properly
	  with non-blocking socket.
	  [Bug #14013] [Bug #14005]

	webrick: fix up r60172 and revert r60189

	Thanks to MSP-Greg (Greg L) for helping with this.

	* lib/webrick/server.rb (start_thread): ignore ECONNRESET, ECONNABORTED,
	  EPROTO, and EINVAL on TLS negotiation errors the same way they
	  were ignored before r60172 in the accept_client method of the
	  main acceptor thread.
	  [Bug #14013] [Bug #14005]

	webrick: fix up r60172 and r60208

	Thanks to MSP-Greg (Greg L) for helping with this.

	* lib/webrick/server.rb (start_thread): fix non-local return
	  introduced in r60208

	webrick: fix up r60172 and r60210

	Thanks to MSP-Greg (Greg L) for helping with this.

	* lib/webrick/server.rb (start_thread): properly fix non-local return
	  introduced in r60208 and r60210
------------------------------------------------------------------------
r61238 | nagachika | 2017-12-14 22:14:12 +0900 (Thu, 14 Dec 2017) | 15 lines

merge revision(s) 61197: [Backport #14184]

	webrick: compile RE correctly for beginning and end match

	Using ^ and $ in regexps means we can accidentally get fooled
	by "%0a" in HTTP request paths being decoded to newline
	characters.  Use \A and \z to match beginning and end-of-string
	respectively, instead.

	Thanks to mame and hsbt for reporting.

	* lib/webrick/httpserver.rb (MountTable#compile):
	  use \A and \z instead of ^ and $
	* lib/webrick/httpserver.rb (MountTable#normalize): use \z instead of $
	* test/webrick/test_httpserver.rb (test_cntrl_in_path): new test
------------------------------------------------------------------------
r60626 | nagachika | 2017-11-03 10:46:59 +0900 (Fri, 03 Nov 2017) | 8 lines

merge revision(s) 58499,58500: [Backport #13181]

	parse.y: fix line in rescue

	* parse.y (set_line_body, primary): fix line number of bodystmt as
	  the beginning of the block.  [ruby-core:79388] [Bug #13181]

	parse.y: set_line_body is not used in ripper
------------------------------------------------------------------------
r60168 | nagachika | 2017-10-11 22:48:14 +0900 (Wed, 11 Oct 2017) | 5 lines

merge revision(s) 60149: [Backport #14003]

	Merge rubygems-2.6.14 changes.

	  It fixed http://blog.rubygems.org/2017/10/09/unsafe-object-deserialization-vulnerability.html
------------------------------------------------------------------------
r59914 | nagachika | 2017-09-15 07:22:39 +0900 (Fri, 15 Sep 2017) | 10 lines

merge revision(s) 58254: [Backport #13402]

	fix --with-gmp (broken by r57490)

	Looking at the generated shell script (also the autoconf manual), it
	seems AC_SEARCH_LIBS() m4 macro does not define HAVE_LIBsomething C
	preprocessor macros, unlike AC_CHECK_LIB() which does define them.
	This previous change effectively killed building with GMP because
	building that mode depends on existence of HAVE_LIBGMP. [Bug #13402]

------------------------------------------------------------------------
r59913 | nagachika | 2017-09-15 07:21:51 +0900 (Fri, 15 Sep 2017) | 1 line

bump up teeny version to 2.4.3.
------------------------------------------------------------------------
r59898 | nagachika | 2017-09-14 20:24:10 +0900 (Thu, 14 Sep 2017) | 6 lines

merge revision(s) 59897:

	lib/webrick/log.rb: sanitize any type of logs

	It had failed to sanitize some type of exception messages.  Reported and
	patched by Yusuke Endoh (mame) at https://hackerone.com/reports/223363
------------------------------------------------------------------------
r59841 | nagachika | 2017-09-12 02:27:01 +0900 (Tue, 12 Sep 2017) | 7 lines

merge revision(s) 59375: [Backport #13756]

	parse.y: empty hash in defined

	* parse.y (command): NODE_ARRAY with NULL is invalid.  traversal
	  in defined_expr0 is simplified than iseq_compile_each0.
	  [ruby-core:82113] [Bug #13756]
------------------------------------------------------------------------
r59823 | nagachika | 2017-09-10 21:33:09 +0900 (Sun, 10 Sep 2017) | 6 lines

merge revision(s) 59765: [Backport #13877]

	ruby.h: unnormalized Fixnum value

	* include/ruby/ruby.h (ST2FIX): fix unnormalized Fixnum value bug
	  on mingw/mswin.  [ruby-core:82687] [Bug #13877]
------------------------------------------------------------------------
r59822 | nagachika | 2017-09-10 21:17:49 +0900 (Sun, 10 Sep 2017) | 7 lines

merge revision(s) 59763: [Backport #13874]

	string.c: fix false coderange

	* string.c (rb_enc_str_scrub): enc can differ from the actual
	  encoding of the string, the cached coderange is useless then.
	  [ruby-core:82674] [Bug #13874]
------------------------------------------------------------------------
r59820 | nagachika | 2017-09-10 19:27:59 +0900 (Sun, 10 Sep 2017) | 6 lines

merge revision(s) 59644: [Backport #13836]

	parse.y: primary should not be 0

	* parse.y (primary): should not be 0, since it can be a receiver.
	  [ruby-core:82447] [Bug #13836]
------------------------------------------------------------------------
r59819 | nagachika | 2017-09-10 19:10:28 +0900 (Sun, 10 Sep 2017) | 7 lines

merge revision(s) 59613: [Backport #13817]

	vm_method.c: alias warning at refined method

	* vm_method.c (rb_method_entry_make): suppress a warning at
	  refined method which will not be redefined.
	  [ruby-core:82385] [Bug #13817]
------------------------------------------------------------------------
r59818 | nagachika | 2017-09-10 15:15:05 +0900 (Sun, 10 Sep 2017) | 2 lines

revert r59813 partially. TestGemRequire#test_realworld_default_gem is not contained in trunk. 
I would like to sync rubygems on ruby_2_4 branch to trunk
------------------------------------------------------------------------
r59817 | nagachika | 2017-09-10 15:03:12 +0900 (Sun, 10 Sep 2017) | 6 lines

merge revision(s) 59649: [Backport #13832]

	gc.c: restore cfp at finalizer

	* gc.c (run_finalizer): restore cfp for the case an exception
	  raised in a finalizer.  [ruby-core:82432] [Bug #13832]
------------------------------------------------------------------------
r59816 | nagachika | 2017-09-10 14:44:27 +0900 (Sun, 10 Sep 2017) | 1 line

revert r59815 partially.
------------------------------------------------------------------------
r59815 | nagachika | 2017-09-10 14:36:09 +0900 (Sun, 10 Sep 2017) | 1 line

bump up RUBY_PATCHLEVEL
------------------------------------------------------------------------
r59814 | nagachika | 2017-09-10 14:23:13 +0900 (Sun, 10 Sep 2017) | 3 lines

lib/rubygems: fix several vulnerabilities in RubyGems; bump to version 2.6.13.
[Backport #13842]

------------------------------------------------------------------------
r59813 | nagachika | 2017-09-10 14:10:55 +0900 (Sun, 10 Sep 2017) | 2 lines

lib/rubygems: bump up RubyGems version to 2.6.12. [Backport #13842]

------------------------------------------------------------------------
r59812 | nagachika | 2017-09-10 13:53:58 +0900 (Sun, 10 Sep 2017) | 6 lines

merge revision(s) 59708: [Backport #13844]

	compile.c: ensure after toplevel return

	* compile.c (iseq_compile_each0): toplevel returns should fire
	  ensures.  [ruby-core:82492] [Bug #13844]
------------------------------------------------------------------------
r59811 | nagachika | 2017-09-10 12:49:10 +0900 (Sun, 10 Sep 2017) | 15 lines

merge revision(s) 59624,59626: [Backport #13830]

	ruby.h: fix rb_scan_args_trail_idx

	* include/ruby/ruby.h (rb_scan_args_trail_idx): fix the case both
	  of optional and rest arguments are defined.
	  [ruby-core:82427] [Bug #13830]

	* include/ruby/ruby.h (rb_scan_args_n_trail): ditto.
	non-keywords hash

	* class.c (rb_scan_args), include/ruby/ruby.h (rb_scan_args_set):
	  return non-keywords elements only in the last hash when keyword
	  arguments are extracted from it, as well as methods defined in
	  ruby level.  [ruby-core:82427] [Bug #13830]
------------------------------------------------------------------------
r59809 | nagachika | 2017-09-10 11:58:23 +0900 (Sun, 10 Sep 2017) | 14 lines

merge revision(s) 59322,59325: [Backport #13744]

	process.c: handle dynamic :rlimit_* symbols in spawn execopts

	* process.c (rb_execarg_addopt_rlimit): hoist out of rb_execarg_addopt
	  (rlimit_type_by_sym): new wrapper for dynamic symbol
	  (rb_execarg_addopt): check for dsym via rlimit_type_by_sym
	* test/ruby/test_process.rb (test_execopts_rlimit): check dsym w/o pindown
	  Add extra check for bogus rlimit args, too.
	  [ruby-core:82033] [Bug #13744]
	process.c: null bytes

	* process.c (rlimit_type_by_sym): prohibit null bytes in key
	  names.  [ruby-core:82033] [Bug #13744]
------------------------------------------------------------------------
r59808 | nagachika | 2017-09-10 11:46:34 +0900 (Sun, 10 Sep 2017) | 7 lines

merge revision(s) 57944,57977,58062: [Backport #13306]

	io.c: [DOC] IO#puts uses IO#write
	io.c: [DOC] add missing `$`
	io.c: [DOC] expand docs for IO#puts

	[ruby-core:80081] [Bug #13306]
------------------------------------------------------------------------
r59807 | nagachika | 2017-09-10 11:40:45 +0900 (Sun, 10 Sep 2017) | 24 lines

merge revision(s) 58524,58525,58526,59333,59337: [Backport #13616]

	zlib.c: zstream_expand_buffer_non_stream

	* ext/zlib/zlib.c (zstream_expand_buffer_non_stream): rename from
	  zstream_expand_buffer_without_gvl() and replace duplicate code
	  in zstream_expand_buffer().
	zlib.c: zstream_buffer_ungetbyte

	* ext/zlib/zlib.c (zstream_buffer_ungetbyte): simplify by using
	  zstream_buffer_ungets().
	zlib.c: no buf_filled in zstream

	* ext/zlib/zlib.c (zstream): manage capacity and size of `buf`
	  instead of size and separated member `buf_filled`.  reported by
	  Christian Jalio (jalio) at https://hackerone.com/reports/211958
	Zlib::GzipReader#pos underflows after calling #ungetbyte or #ungetc at start of file [Bug #13616]

	patched by Andrew Haines <andrew@haines.org.nz> [ruby-core:81488]
	zlib.c: fix unnormalized Fixnum

	* ext/zlib/zlib.c (rb_gzfile_total_out): cast to long not to
	  result in an unsigned long to normalized to Fixnum on LLP64
	  platforms.  [ruby-core:81488]
------------------------------------------------------------------------
r59784 | nagachika | 2017-09-08 23:38:12 +0900 (Fri, 08 Sep 2017) | 28 lines

merge revision(s) 59567: [Backport #13796]

	openssl: import v2.0.5

	Import Ruby/OpenSSL 2.0.5. The full commit history since v2.0.4
	(imported at r59081) can be found at:

		https://github.com/ruby/openssl/compare/v2.0.4...v2.0.5

	This will fix the test failure on latest Debian sid and the "no
	OPENSSL_Applink" issue on mswin.

	----------------------------------------------------------------
	Kazuki Yamaguchi (11):
	      test/test_ssl: allow 3DES cipher suites in test_sslctx_set_params
	      bio: prevent possible GC issue in ossl_obj2bio()
	      bio: do not use the FILE BIO method in ossl_obj2bio()
	      Rakefile: install_dependencies: install only when needed
	      appveyor.yml: test against Ruby 2.4
	      ossl_pem_passwd_cb: relax passphrase length constraint
	      ossl_pem_passwd_cb: do not check for taintedness
	      ossl_pem_passwd_cb: handle nil from the block explicitly
	      ssl: remove unsupported TLS versions from SSLContext::METHODS
	      ssl: fix compile error with OpenSSL 1.0.0
	      Ruby/OpenSSL 2.0.5

	Lars Kanis (1):
	      Add msys2 library dependency tag in gem metadata
------------------------------------------------------------------------
r59783 | nagachika | 2017-09-08 23:27:38 +0900 (Fri, 08 Sep 2017) | 7 lines

merge revision(s) 59693,59695: [Backport #13852]

	A HTTP Header value must not contain CR or LF.
	to_str -> to_s

	* lib/net/http/header.rb (set_field): `val` can not have `to_str`.

------------------------------------------------------------------------
r59782 | nagachika | 2017-09-08 23:25:52 +0900 (Fri, 08 Sep 2017) | 8 lines

merge revision(s) 59584: [Backport #13850]

	REXML: Fix a bug that unexpected methods can be called as a XPath function

	[HackerOne:249295]

	Reported by Andrea Jegher. Thanks!!!

------------------------------------------------------------------------
r59520 | nagachika | 2017-08-05 16:00:33 +0900 (Sat, 05 Aug 2017) | 11 lines

merge revision(s) 59457: [Backport #13775]

	should not copy promoted flags.

	* include/ruby/ruby.h (rb_clone_setup): should not copy some flags
	  (FL_PROMOTED0|FL_PROMOTED1|FL_FINALIZE).
	  [Bug #13775]

	* test/ruby/test_object.rb: add a test (note that this test will fail
	  only when RGENGC_CHECK_MODE >= 2).

------------------------------------------------------------------------
r59517 | nagachika | 2017-08-05 15:46:23 +0900 (Sat, 05 Aug 2017) | 6 lines

merge revision(s) 59368: [Backport #13753]

	random.c: ensure initialized

	* random.c (get_rnd, try_get_rnd): ensure initialized to get rid
	  of crash in forked processes.  [ruby-core:82100] [Bug #13753]
------------------------------------------------------------------------
r59516 | nagachika | 2017-08-05 15:35:02 +0900 (Sat, 05 Aug 2017) | 30 lines

merge revision(s) 59462,59474: [Backport #13772]

	release VM stack properly.

	* cont.c: r55766 change the handling method of Fiber's VM stack.
	  Resumed Fiber points NULL as VM stack and running Thread has
	  responsibility to manage it (marking and releasing).

	  However, thread_start_func_2()@thread.c and thread_free()@vm.c
	  doesn't free the VM stack if corresponding root Fiber is exist.
	  This causes memory leak. [Bug #13772]

	* cont.c (root_fiber_alloc): fib->cont.saved_thread.ec.stack should be NULL
	  because running thread has responsibility to manage this stack.

	* vm.c (rb_thread_recycle_stack_release): assert given stack is not NULL
	  (callers should care it).

	fix stack storing for root fibers.

	* cont.c (root_fiber_alloc): this function is called by fiber_current()
	  and fiber_store(). fiber_current() should clear VM stack information
	  in a fiber data because runnning thread knows stack information and has
	  responsibility to manage it. However fiber_store() requires to remain
	  VM stack information in a fiber data because the responsibility to manage
	  VM stack is moved to the Fiber from the Thread (and switch to another
	  fiber).

	* cont.c (root_fiber_alloc): save thread's fiber and root_fiber information.

------------------------------------------------------------------------
r59515 | nagachika | 2017-08-05 12:24:54 +0900 (Sat, 05 Aug 2017) | 8 lines

merge revision(s) 59128: [Backport #13669]

	Fix Enumerable#uniq with non single yield arguments

	* enum.c (uniq_func, uniq_iter): need packed value as the unique
	  key.  [ruby-core:81734] [Bug #13669] [Fix GH-1658]

	Author:    Kenichi Kamiya <kachick1@gmail.com>
------------------------------------------------------------------------
r59514 | nagachika | 2017-08-05 11:43:08 +0900 (Sat, 05 Aug 2017) | 10 lines

merge revision(s) 58810,58894: [Backport #13578]

	compile.c: fix catch-table labels optimization

	* compile.c (remove_unreachable_chunk): do not eliminate chunks
	  followed by labels in catch-table entries.
	compile.c: fix possible use of uninitialized value

	LABEL::unremovable added by r58810 is not initialized by
	new_label_body(), making the optimization unstable.
------------------------------------------------------------------------
r59513 | nagachika | 2017-08-05 11:22:37 +0900 (Sat, 05 Aug 2017) | 7 lines

merge revision(s) 58561: [Backport #13540]

	parse.y: make shared string modifiable

	* parse.y (dedent_string): ensure that the string is modifiable,
	  not to set the length of shared string.
	  [ruby-core:80987] [Bug #13540]
------------------------------------------------------------------------
r59512 | nagachika | 2017-08-05 10:56:55 +0900 (Sat, 05 Aug 2017) | 11 lines

merge revision(s) 58205: [Backport #13380]

	Remove unused Init_frozen_strings declaration

	Init_frozen_strings definition is removed in r51511.
	https://bugs.ruby-lang.org/issues/11423

	Patch by Kohei Suzuki <eagletmt@gmail.com>

	* internal.h: Remove declaration of unexist function
	  [Fix GH-1558]
------------------------------------------------------------------------
r59511 | nagachika | 2017-08-05 10:53:44 +0900 (Sat, 05 Aug 2017) | 11 lines

merge revision(s) 57501,58576: [Backport #13539]

	escape.c: check argument

	* ext/cgi/escape/escape.c (optimized_unescape): check
	  accept_charset encoding argument.
	share `@@accept_charset`

	* lib/cgi/{core,util}.rb: include CGI::Util not only extending, to
	  share `@@accept_charset` class variable, so that it is always
	  accessible.  [ruby-core:80986] [Bug #13539]
------------------------------------------------------------------------
r59510 | nagachika | 2017-08-05 10:45:39 +0900 (Sat, 05 Aug 2017) | 9 lines

merge revision(s) 58523: [Backport #13528]

	rational.c: canonicalization case

	* rational.c (float_numerator, float_denominator): fix for
	  canonicalization case where `Float#to_r` could return an Integer
	  not a Rational.  although mathn.rb has been removed in the
	  trunk, fix for the backport purpose.
	  [ruby-core:80942] [Bug #13528]
------------------------------------------------------------------------
r59507 | nagachika | 2017-08-05 01:13:13 +0900 (Sat, 05 Aug 2017) | 7 lines

merge revision(s) 59374: [Backport #13755]

	compile.c: restore stack at return

	* compile.c (iseq_compile_each0): restore the stack depth after
	  return to the previous depth, to fix the stack depth at
	  returning from rescue iseq.  [ruby-core:82108] [Bug #13755]
------------------------------------------------------------------------
r59506 | nagachika | 2017-08-05 00:55:45 +0900 (Sat, 05 Aug 2017) | 7 lines

merge revision(s) 59384: [Backport #13759]

	strscan.c: fix segfault in aref

	* ext/strscan/strscan.c (strscan_aref): fix segfault after
	  get_byte or getch which do not apply regexp.
	  [ruby-core:82116] [Bug #13759]
------------------------------------------------------------------------
r59505 | nagachika | 2017-08-05 00:29:45 +0900 (Sat, 05 Aug 2017) | 6 lines

merge revision(s) 58913: [Backport #13599]

	numeric.c: fix for small number

	* numeric.c (flo_floor, flo_ceil): should not return zero for small
	  number.  [ruby-core:81394] [Bug #13599]
------------------------------------------------------------------------
r59504 | svn | 2017-08-05 00:06:23 +0900 (Sat, 05 Aug 2017) | 1 line

* 2017-08-05
------------------------------------------------------------------------
r59503 | nagachika | 2017-08-05 00:06:22 +0900 (Sat, 05 Aug 2017) | 9 lines

merge revision(s) 59063: [Backport #13605]


	* proc.c (get_local_variable_ptr): return found env ptr. Returned env
	  will be used by write barrier at `bind_local_variable_set()'.
	  [Bug #13605]

	* test/ruby/test_proc.rb: add a test for this issue.

------------------------------------------------------------------------
r59501 | nagachika | 2017-08-04 23:39:29 +0900 (Fri, 04 Aug 2017) | 6 lines

merge revision(s) 58287: [Backport #13411]

	configure.in: rpath with OPTDIR

	* configure.in: add rpath flags which is needed for OPTDIR as well
	  as -L options, when it is given.  [ruby-dev:50065] [Bug #13411]
------------------------------------------------------------------------
r59500 | nagachika | 2017-08-04 23:31:52 +0900 (Fri, 04 Aug 2017) | 16 lines

merge revision(s) 59357,59358: [Backport #13391] [Backport #13404]

	proc.c: rb_block_min_max_arity

	* proc.c (rb_block_min_max_arity): new function to get arity range
	  from the current block.
	vm_eval.c: rb_lambda_call

	* enum.c (enum_collect): make the block arity same as the given
	  block.  [Bug #13391]

	* internal.h (vm_ifunc): store arity instead of unused id.

	* proc.c (rb_vm_block_min_max_arity): return ifunc arity.

	* vm_eval.c (rb_lambda_call): call method with lambda block.
------------------------------------------------------------------------
r59493 | nagachika | 2017-08-04 01:00:34 +0900 (Fri, 04 Aug 2017) | 15 lines

merge revision(s) 59183,59184: [Backport #13682]

	fix return in toplevel rescue/ensure

	* compile.c (iseq_compile_each0): throw TAG_RETURN at return in
	  toplevel rescue/ensure to adjust VM stack properly.
	  [ruby-core:81777] [Bug #13682]

	* vm_insnhelper.c (vm_throw_start): allow return in toplevel
	  rescue/ensure.
	fix return in toplevel ensure

	* compile.c (iseq_compile_each0): adjust stack after return in
	  toplevel ensure, when the value is used.
	  [ruby-core:81777] [Bug #13682]
------------------------------------------------------------------------
r59492 | nagachika | 2017-08-04 00:41:24 +0900 (Fri, 04 Aug 2017) | 8 lines

merge revision(s) 59202: [Backport #13690]

	compile.c: disallow next in once

	* compile.c (iseq_compile_each0): turned dregx context in "once"
	  into "guarded" type from "block" type, to disallow `next`,
	  `break`, `redo` as well as outside "once".
	  [ruby-core:81805] [Bug #13690]
------------------------------------------------------------------------
r59491 | nagachika | 2017-08-04 00:40:10 +0900 (Fri, 04 Aug 2017) | 8 lines

merge revision(s) 59181: [Backport #13680]

	vm_insnhelper.c: break in once

	* vm_insnhelper.c (vm_throw_start): size of catch table has been
	  included in iseq_catch_table struct, which could be NULL, since
	  2.2.  e.g., proc-closure in `once'.
	  [ruby-core:81775] [Bug #13680]
------------------------------------------------------------------------
r59490 | nagachika | 2017-08-03 23:00:41 +0900 (Thu, 03 Aug 2017) | 7 lines

merge revision(s) 59169: [Backport #13678]

	compile.c: toplevel return in argument

	* compile.c (iseq_compile_each0): adjust the stack before return
	  in an evstr/argument (reported by Balazs <balazs@kutilovi.cz>)
	  to fix stack consistency error.  [ruby-core:81761] [Bug #13678]
------------------------------------------------------------------------
r59489 | nagachika | 2017-08-03 22:43:01 +0900 (Thu, 03 Aug 2017) | 43 lines

merge revision(s) 58742,59081: [Backport #11033]

	Search SSL libraries by testing various filename patterns

	* ext/openssl/extconf.rb (find_openssl_library): should search by more flexible
	  method, especially for LibreSSL on Windows.

	openssl: import v2.0.4

	Import Ruby/OpenSSL 2.0.4. Only bug (and typo) fixes. The full commit
	history since v2.0.3 (imported at r57482) can be found at:

	  https://github.com/ruby/openssl/compare/v2.0.3...v2.0.4

	This contains the fix for [Bug #11033].

	----------------------------------------------------------------
	Jun Aruga (1):
	      Update .travis.yml and Dockerfile

	Kazuki Yamaguchi (9):
	      test/test_pkey_ec: do not use dummy 0 order
	      test/test_ssl: fix typo in test_sysread_and_syswrite
	      ssl: check return value of SSL_set_fd()
	      Fix typos
	      test/test_x509store: skip OpenSSL::TestX509Store#test_set_errors
	      tool/sync-with-trunk: 'LASY' -> 'LAST'
	      x509store: clear error queue after calling X509_LOOKUP_load_file()
	      extconf.rb: simplify searching libraries logic
	      Ruby/OpenSSL 2.0.4

	SHIBATA Hiroshi (1):
	      Fix typos

	Vladimir Rybas (1):
	      Fix documentation for OpenSSL::Cipher#final

	nobu (2):
	      openssl: fix broken openssl check
	      openssl: fix broken openssl check

	usa (1):
	      Search SSL libraries by testing various filename patterns
------------------------------------------------------------------------
r59488 | nagachika | 2017-08-03 22:29:12 +0900 (Thu, 03 Aug 2017) | 8 lines

merge revision(s) 58503: [Backport #13523]

	node.h: sign-extend

	* node.h (nd_line): should sign-extend.  shifting `VALUE` extends
	  with zero bits if `sizeof(VALUE)` equals to `sizeof(int)`.  the
	  zero bits are truncated if `sizeof(VALUE)` is bigger enough.
	  [ruby-core:80920] [Bug #13523]
------------------------------------------------------------------------
r59409 | nagachika | 2017-07-23 17:59:07 +0900 (Sun, 23 Jul 2017) | 9 lines

merge revision(s) 58641: [Backport #13547]

	parse.y: brace after literal arg

	* parse.y (symbol, dsym, parser_set_number_literal, parser_yylex):
	  set state to END too not only ENDARG and after a literal, so
	  that a left brace after it should be a primary block bound to
	  the literal, which causes syntax error.
	  [ruby-core:81037] [Bug #13547]
------------------------------------------------------------------------
r59408 | nagachika | 2017-07-23 17:49:34 +0900 (Sun, 23 Jul 2017) | 11 lines

merge revision(s) 58902: [Backport #13595]

	attempt to fix rb_alloc_tmp_buffer2 for ALLOCV_N

	This is a confusing function to my arithmetic-challenged mind,
	but nobu seems alright with this.  Anyways this lets me use
	large values of elsize without segfaulting, and "make exam"
	passes.

	* include/ruby/ruby.h (rb_alloc_tmp_buffer2): attempt to fix
	  [ruby-core:81388] [ruby-core:81391] [Bug #13595]
------------------------------------------------------------------------
r59407 | nagachika | 2017-07-23 17:39:46 +0900 (Sun, 23 Jul 2017) | 13 lines

merge revision(s) 58077,58229: [Backport #13358]

	ostruct.rb: fix OpenStruct.allocate

	* lib/ostruct.rb (OpenStruct.allocate): initialize an instance
	  variable directly, without calling `intialize` method which may
	  be overridden in a subclass.  [ruby-core:80292] [Bug #13358]
	ostruct.rb: improve fix for OpenStruct.allocate + #respond_to?

	* lib/ostruct.rb (OpenStruct#respond_to_missing?): this makes
	  OpenStruct#respond_to? works on any OpenStruct instance,
	  just like Kernel#respond_to? does, without workarounds.
	  [ruby-core:80292] [Bug #13358]
------------------------------------------------------------------------
r59406 | nagachika | 2017-07-23 17:15:57 +0900 (Sun, 23 Jul 2017) | 12 lines

merge revision(s) 58638,58640: [Backport #11873]

	test_syntax.rb: test_brace_after_local_variable

	* test/ruby/test_syntax.rb (test_brace_after_local_variable):
	  another test using braces.  [Bug #11873]
	parse.y: do after cmdarg in paren

	* parse.y (parser_yylex): set state to ENDARG after a string
	  literal, so that `do` after a literal should be `do_block` and
	  bound to the outer method, as well as a numeric/symbol literal.
	  [ruby-core:72482] [Bug #11873]
------------------------------------------------------------------------
r59405 | nagachika | 2017-07-23 17:05:15 +0900 (Sun, 23 Jul 2017) | 9 lines

merge revision(s) 59307: [Backport #13284]

	a64: fix crash on register stack mark/sweep pass

	* thread_pthread.c: move 'register_stack_start' earlier.
	  [ruby-core:79928] [Bug #13284] [Fix GH-1625]

	Author:    Sergei Trofimovich <slyfox@gentoo.org>

------------------------------------------------------------------------
r59404 | nagachika | 2017-07-23 16:50:10 +0900 (Sun, 23 Jul 2017) | 7 lines

merge revision(s) 57530: [Backport #13191]

	sample/pty/shl.rb: update sample

	* Specify frozen_string_literal: true.
	* Fix TypeError of raise.
	* Use a character literal instead of Integer.
------------------------------------------------------------------------
r59403 | nagachika | 2017-07-23 16:48:31 +0900 (Sun, 23 Jul 2017) | 7 lines

merge revision(s) 59002: [Backport #13621]

	string.c: docs for String#split

	* string.c: [DOC] clarify docs for String#split when called
	  with limit and capture groups.
	  Reported by Cichol Tsai.  [ruby-core:81505] [Bug #13621]
------------------------------------------------------------------------
r59402 | nagachika | 2017-07-23 16:46:05 +0900 (Sun, 23 Jul 2017) | 6 lines

merge revision(s) 57446: [Backport #13413]

	mkmf.rb: fix script installation

	* lib/mkmf.rb (MakeMakefile): fix condition to install script
	  files.
------------------------------------------------------------------------
r59401 | nagachika | 2017-07-23 16:44:56 +0900 (Sun, 23 Jul 2017) | 7 lines

merge revision(s) 59161: [Backport #13672]

	parse.y: check multibyte char

	* parse.y (parser_precise_mbclen): check invalid multibyte char at
	  skipping strings following `?x` literal string, not to stuck in
	  a infinite loop.  [ruby-core:81746] [Bug #13672]
------------------------------------------------------------------------
r59400 | nagachika | 2017-07-23 16:36:10 +0900 (Sun, 23 Jul 2017) | 8 lines

merge revision(s) 59102: [Backport #13515]

	pathname.rb: UNC root pathname needs a separator

	* ext/pathname/lib/pathname.rb (Pathname#plus): UNC root pathname
	  needs a separator.  File.basename returns "/" on UNC root, as
	  well as sole drive letter, even if it does not end with a
	  separator.  [ruby-core:80900] [Bug #13515]
------------------------------------------------------------------------
r59399 | nagachika | 2017-07-23 16:33:07 +0900 (Sun, 23 Jul 2017) | 9 lines

merge revision(s) 59033,59034: [Backport #13636]

	rexml: add close tag check on end of document to StreamParser

	[ruby-core:81593] [Bug #13636]

	Reported by Anton Sivakov. Thanks!!!

	* properties.
------------------------------------------------------------------------
r59398 | nagachika | 2017-07-23 16:30:43 +0900 (Sun, 23 Jul 2017) | 6 lines

merge revision(s) 58693: [Backport #13558]

	array.c: check position to insert

	* array.c (rb_ary_insert): check position to insert even if no
	  elements to be inserted.  [ruby-core:81125] [Bug #13558]
------------------------------------------------------------------------
r59397 | nagachika | 2017-07-23 16:21:04 +0900 (Sun, 23 Jul 2017) | 9 lines

merge revision(s) 58643: [Backport #13231]

	date_core.c: fix docs for %Z format

	* ext/date/date_core.c: [DOC] fix documentation for %Z format
	  of {Date,DateTime}.strftime.

	  Reported by Damon Timm.  Based on a patch by nano.
	  [ruby-core:79602] [Bug #13231] [Fix GH-1565]
------------------------------------------------------------------------
r59396 | nagachika | 2017-07-23 16:20:05 +0900 (Sun, 23 Jul 2017) | 10 lines

merge revision(s) 58552: [Backport #13531]

	rss: Accept empty text element as valid element

	Parser has been accepted it but XML serializer wasn't accepted.

	Reported by stefano frabetti. Thanks!!!

	[ruby-core:80965] [Bug #13531]

------------------------------------------------------------------------
r59395 | nagachika | 2017-07-23 16:02:29 +0900 (Sun, 23 Jul 2017) | 8 lines

merge revision(s) 59080,59082: [Backport #13656]

	proc.c: skip prepended modules

	* proc.c (method_super_method): skip prepended modules and
	  continue from the super class of the original class.
	  [ruby-core:81666] [Bug #13656]
	test/ruby/test_method.rb: refined  [ruby-core:81666] [Bug #13656]
------------------------------------------------------------------------
r59363 | nagachika | 2017-07-18 21:42:38 +0900 (Tue, 18 Jul 2017) | 9 lines

merge revision(s) 59056: [Backport #13648] [Backport #13699]

	enumerator.c: fix nested maps

	* enumerator.c (lazy_map_proc, lazy_grep_iter_proc): marks values
	  returned by blocks are not packed in the case of nested maps, so
	  that the result will be same as non-lazy version.  based on the
	  patch by akihikodaki (Akihiko Odaki) at [ruby-core:81638],
	  without GCC extension.  [Bug#13648]
------------------------------------------------------------------------
r59316 | nagachika | 2017-07-12 23:06:21 +0900 (Wed, 12 Jul 2017) | 6 lines

merge revision(s) 59312: [Backport #13739]

	optparse.rb: get rid of eval

	* lib/optparse.rb: try Float() and Integer() instead of eval,
	  which does too much things.
------------------------------------------------------------------------
r59303 | nagachika | 2017-07-10 05:46:10 +0900 (Mon, 10 Jul 2017) | 28 lines

merge revision(s) 58696: [Backport #11384]

	autoload: always wait on loading thread

	We cannot assume autoload_provided/rb_feature_provided returning
	TRUE means it is safe to proceed without waiting.  Another
	thread may call rb_provide_feature before setting the constant
	(via autoload_const_set).  So we must wait until autoload is
	completed by another thread.

	Note: this patch was tested with an explicit rb_thread_schedule
	in rb_provide_feature to make the race condition more apparent
	as suggested by <s.wanabe@gmail.com>:
	> --- a/load.c
	> +++ b/load.c
	> @@ -563,6 +563,7 @@ rb_provide_feature(VALUE feature)
	>      rb_str_freeze(feature);
	>
	>      rb_ary_push(features, rb_fstring(feature));
	> +rb_thread_schedule();
	>      features_index_add(feature, INT2FIX(RARRAY_LEN(features)-1));
	>      reset_loaded_features_snapshot();
	>  }

	* variable.c (check_autoload_required): do not assume a provided
	  feature means autoload is complete, always wait if autoload is
	  being performed by another thread.
	  [ruby-core:81105] [Bug #11384] Thanks to <s.wanabe@gmail.com>
------------------------------------------------------------------------
r59302 | nagachika | 2017-07-10 05:24:02 +0900 (Mon, 10 Jul 2017) | 13 lines

merge revision(s) 56558,59116,59136: [Backport #12670]

	* gc.c (heap_page_resurrect): do not return tomb_pages when
	  page->freelist == NULL.
	  [Bug #12670]

	test for [Bug #12670]

	heap corruption by deferred free.
	gc.c: expand sorted pages

	* gc.c (heap_page_allocate): expand sorted pages before inserting
	  allocated new page.  [Bug #12670]
------------------------------------------------------------------------
r59301 | nagachika | 2017-07-10 05:06:31 +0900 (Mon, 10 Jul 2017) | 10 lines

merge revision(s) 58825,58826: [Backport #5339]

	erb.rb: Allow explicit trimming carriage return

	when trim_mode is "-", for Windows environments.

	[ruby-core:39625] [Bug #5339]
	erb.rb: Allow trimming CR in all trim_modes

	to unify a behavior with r58823 and r58825.
------------------------------------------------------------------------
r59300 | nagachika | 2017-07-10 05:04:25 +0900 (Mon, 10 Jul 2017) | 7 lines

merge revision(s) 58823: [Backport #11464]

	erb.rb: Allow trimming carriage return

	when trim_mode is "<>", for Windows environments.

	[Bug #11464]
------------------------------------------------------------------------
r59299 | nagachika | 2017-07-10 05:02:04 +0900 (Mon, 10 Jul 2017) | 6 lines

merge revision(s) 58210: [Backport #8916]

	vsnprintf.c: prefix with precision

	* vsnprintf.c (BSD_vfprintf): sign and hex-prefix should not be
	  counted in precision.  [ruby-dev:47714] [Bug #8916]
------------------------------------------------------------------------
r59298 | nagachika | 2017-07-10 04:51:43 +0900 (Mon, 10 Jul 2017) | 5 lines

merge revision(s) 58796: [Backport #13545]

	Merge latest dtoa.c [Bug #13545]

	Apply some part of http://www.netlib.org/fp/dtoa.c with my eyes...
------------------------------------------------------------------------
r59297 | nagachika | 2017-07-10 04:49:03 +0900 (Mon, 10 Jul 2017) | 22 lines

merge revision(s) 58334,58346,58349: [Backport #13425] [Backport #13432]

	thread.c: disable VM events when stack overflow

	* thread.c (ruby_thread_stack_overflow): disable VM events when
	  stack overflow occurred; it causes another stack overflow again
	  in making backtrace object, and crashes.
	  [ruby-core:80662] [Bug #13425]
	increase timeout seconds.

	* test/ruby/test_trace.rb (test_trace_stackoverflow): on some platforms
	  this test fails because of timeout.

	disable rewind hooks.

	* vm.c (hook_before_rewind): skip rewind hooks if err is SystemStackError
	  because rewind hooks can cause stack overflow again and again.

	* thread.c (ruby_thread_stack_overflow): do not disable all hooks.
	  Additionally, clearing ruby_vm_event_flags is not suitable way
	  to disable hooks.

------------------------------------------------------------------------
r59296 | nagachika | 2017-07-10 04:47:28 +0900 (Mon, 10 Jul 2017) | 18 lines

merge revision(s) 58262,5826: [Backport #13369]

	fix TracePoint#return_value with non-local exits

	* vm.c: get return_value from imemo_throw_data object (THROW_DATA_VAL()).
	  imemo_throw_data (TAG_BREAK) contains returned value.
	  However, imemo_throw_data (TAG_BREAK) can skip several frames so that
	  we need to use it only once (at most internal frame). To record it,
	  we introduced THROW_DATA_CONSUMED and check it.

	* internal.h: define THROW_DATA_CONSUMED flag.

	* test/ruby/test_settracefunc.rb: add tests for [Bug #13369]

	* vm_insnhelper.h: add THROW_DATA_CONSUMED_P() and
	  THROW_DATA_CONSUMED_SET().
	  unless File::FNM_DOTMATCH is set. (like '*/') [ruby-dev:23014]

------------------------------------------------------------------------
r59295 | nagachika | 2017-07-10 04:36:49 +0900 (Mon, 10 Jul 2017) | 13 lines

merge revision(s) 59030,59031: [Backport #13638]

	thread.c: avoid busy looping on rb_thread_fd_close

	We no longer use it this function, but extensions do, and
	we need to ensure it continues to work for them.

	* thread.c (rb_thread_fd_close): schedule other threads in loop
	* ext/-test-/thread_fd_close/thread_fd_close.c: new file
	* ext/-test-/thread_fd_close/depend: ditto
	* ext/-test-/thread_fd_close/extconf.rb: ditto
	* test/-ext-/thread_fd_close/test_thread_fd_close.rb: new test
	* properties.
------------------------------------------------------------------------
r59294 | nagachika | 2017-07-10 04:27:57 +0900 (Mon, 10 Jul 2017) | 6 lines

merge revision(s) 57248: [Backport #13573]

	 dir.c: getattrlist on OSX 10.5

	* dir.c (is_case_sensitive): use getattrlist() if fgetattrlist()
	  is unavailable, on OSX 10.5.  [ruby-core:68829] [Bug #11054]
------------------------------------------------------------------------
r59293 | nagachika | 2017-07-10 04:02:35 +0900 (Mon, 10 Jul 2017) | 7 lines

merge revision(s) 58658: [Backport #13554]

	process.c: temporary string for buffer

	* process.c (obj2uid, obj2gid): use temporary string as the buffer
	  instead of `rb_alloc_tmp_buffer`, which is `NODE_ALLOCA` since
	  r51492.  [ruby-core:81084] [Bug #13554]
------------------------------------------------------------------------
r59286 | nagachika | 2017-07-08 11:21:36 +0900 (Sat, 08 Jul 2017) | 55 lines

merge revision(s) 58284,58812,59028: [Backport #13632]

	vm_core.h: ruby_error_stream_closed

	* vm_core.h (ruby_special_exceptions): renamed
	  ruby_error_closed_stream as ruby_error_stream_closed, like the
	  message.
	speed up IO#close with many threads

	Today, it increases IO#close performance with many threads:

	  Execution time (sec)
	  name            trunk   after
	  vm_thread_close 4.276   3.018

	  Speedup ratio: compare with the result of `trunk' (greater is better)
	  name            after
	  vm_thread_close 1.417

	This speedup comes because rb_notify_fd_close only scans threads
	inside rb_thread_io_blocking_region, not all threads in the VM.

	In the future, this type data structure may allow us to notify
	waiters of multiple FDs on a single thread (when using
	Fibers).

	* thread.c (struct waiting_fd): declare
	  (rb_thread_io_blocking_region): use on-stack list waiter
	  (rb_notify_fd_close): walk vm->waiting_fds instead
	  (call_without_gvl): remove old field setting
	  (th_init): ditto
	* vm_core.h (typedef struct rb_vm_struct): add waiting_fds list
	* (typedef struct rb_thread_struct): remove waiting_fd field
	  (rb_vm_living_threads_init): initialize waiting_fds list

	I am now kicking myself for not thinking about this 3 years ago
	when I introduced ccan/list in [Feature #9632] to optimize this
	same function :<
	IO#close: do not enqueue redundant interrupts (take #2)

	Enqueuing multiple errors for one event causes spurious errors
	down the line, as reported by Nikolay Vashchenko in
	https://bugs.ruby-lang.org/issues/13632

	This should fix bad interactions with test_race_gets_and_close
	in test/ruby/test_io.rb since we ensure rb_notify_fd_close
	continues returning the busy flag after enqueuing the interrupt.

	Backporting changes to 2.4 and earlier releases will be more
	challenging...

	* thread.c (rb_notify_fd_close): do not enqueue multiple interrupts
	  [ruby-core:81581] [Bug #13632]
	* test/ruby/test_io.rb (test_single_exception_on_close):
	  new test based on script from Nikolay
------------------------------------------------------------------------
r59247 | nagachika | 2017-07-01 20:51:13 +0900 (Sat, 01 Jul 2017) | 13 lines

merge revision(s) 58545,58584: [Backport #13536]

	ripper/lexer.rb: nested indented heredoc

	* ext/ripper/lib/ripper/lexer.rb (on_heredoc_dedent): fix for
	  nested indedented here documents, where `Elem`s are nested too.
	  [ruby-core:80977] [Bug #13536]
	ripper/lexer.rb: nested indented heredoc

	* ext/ripper/lib/ripper/lexer.rb (on_heredoc_dedent): insert
	  stripped leading spaces as `on_ignored_sp` elements, so that the
	  original source can be reconsructed.
	  [ruby-core:80977] [Bug #13536]
------------------------------------------------------------------------
r58637 | nagachika | 2017-05-10 00:42:52 +0900 (Wed, 10 May 2017) | 13 lines

merge revision(s) 58587,58588: [Backport #13526]

	variable.c: cleanup waitq upon thread death

	* variable.c (autoload_reset): use idempotent list_del_init
	  (autoload_sleep): moved code from rb_autoload_load
	  (autoload_sleep_done): cleanup for use with rb_ensure
	  (rb_autoload_load): ensure list delete happens in case the
	  thread dies during sleep
	* test/ruby/bug-13526.rb: new script for separate execution
	* test/ruby/test_autoload.rb (test_bug_13526): new test
	  [ruby-core:81016] [Bug #13526]
	* properties.
------------------------------------------------------------------------
r58636 | nagachika | 2017-05-10 00:30:19 +0900 (Wed, 10 May 2017) | 11 lines

merge revision(s) 58359: [Backport #13439]

	fix RSTRUCT_LEN macro in public C API

	rb_struct_size returns an Integer VALUE, so it must be converted
	to a `long` for compatibility with previous Ruby C API versions.

	* ext/-test-/struct/len.c: new
	* test/-ext-/struct/test_len.rb: new
	* include/ruby/ruby.h (RSTRUCT_LEN): use NUM2LONG
	  [ruby-core:80692] [Bug #13439]
------------------------------------------------------------------------
r58635 | nagachika | 2017-05-10 00:24:13 +0900 (Wed, 10 May 2017) | 7 lines

merge revision(s) 58211: [Backport #13387]

	string.c: Supress logical-op-parentheses warning

	* string.c(rb_str_upcase_bang): Supress logical-op-parentheses warning
	  Patch by Fukuo Kadota <fukuo-kadota@cookpad.com>,
	  Closes [GH-1570] [Bug #13387].
------------------------------------------------------------------------
r58634 | nagachika | 2017-05-10 00:13:55 +0900 (Wed, 10 May 2017) | 7 lines

merge revision(s) 58398: [Backport #13444]

	compile.c: wrong optimization

	* compile.c (compile_branch_condition): expression which has side
	  effects should not be eliminated.
	  [ruby-core:80740] [Bug #13444]
------------------------------------------------------------------------
r58633 | svn | 2017-05-10 00:06:00 +0900 (Wed, 10 May 2017) | 1 line

* 2017-05-10
------------------------------------------------------------------------
r58632 | nagachika | 2017-05-10 00:05:59 +0900 (Wed, 10 May 2017) | 11 lines

merge revision(s) 58082,58083: [Backport #13236]

	class.c: ensure_includable

	* class.c (ensure_includable): extract checks to include and
	  prepend.
	class.c: prohibit refinement module

	* class.c (ensure_includable): cannot include refinement
	  module, or the type and the class do not match.
	  [ruby-core:79632] [Bug #13236]
------------------------------------------------------------------------
r58631 | nagachika | 2017-05-09 23:56:38 +0900 (Tue, 09 May 2017) | 8 lines

merge revision(s) 57640: [Backport #13214]

	fileutils.rb: do not make root

	* lib/fileutils.rb (FileUtils#mkdir_p): no need to make root
	  directory which should be exist and cannot be made with mkdir
	  recent Cygwin can make a directory contains a colon.
	  [Bug #13214]
------------------------------------------------------------------------
r58630 | nagachika | 2017-05-09 23:55:29 +0900 (Tue, 09 May 2017) | 13 lines

merge revision(s) 57265,57266: [Backport #13081]

	win32/resolv.rb: ad hoc workaround

	* ext/win32/lib/win32/resolv.rb (Win32::Resolv::SZ): an ad hoc
	  workaround for broken registry.  SearchList and other registry
	  values must be REG_SZ, or Windows ignores anything in those
	  values otherwise.  [ruby-dev:49924] [Bug #13081]
	  https://github.com/rubygems/rubygems/issues/1700
	win32/registry.rb: registry type names

	* ext/win32/lib/win32/registry.rb (Win32::Registry#read): show
	  registry type names instead of numeric values.
------------------------------------------------------------------------
r58629 | nagachika | 2017-05-09 23:53:44 +0900 (Tue, 09 May 2017) | 6 lines

merge revision(s) 58037: [Backport #10944]

	docs for creating arrays

	* array.c: [DOC] add example for Array.new with block and index.
	  Reported by Don Cruickshank.  [ruby-core:68442] [Bug #10944]
------------------------------------------------------------------------
r58628 | nagachika | 2017-05-09 23:51:48 +0900 (Tue, 09 May 2017) | 12 lines

merge revision(s) 58008: [Backport #9294]

	io.c: improve docs

	* io.c: [DOC] improve and harmonize docs for IO#read and ARGF#read;
	  fix invalid example code for IO#read to make it syntax highlighted.

	* io.c: [DOC] various improvements for docs of IO, ARGF, and Kernel:
	  fix indent to ensure correct code block detection; sync "outbuf"
	  paragraph for {IO,ARGF}#read, {IO,ARGF}#readpartial, and IO#sysread;
	  fix formatting of call-seq's; improve Kernel#open example to use nil?;
	  fix RDoc markup and typos.
------------------------------------------------------------------------
r58627 | nagachika | 2017-05-09 23:50:45 +0900 (Tue, 09 May 2017) | 7 lines

merge revision(s) 57490: [Backport #13175]

	configure.in: use AC_SEARCH_LIBS

	* configure.in (--with-gmp, --with-jemalloc): use AC_SEARCH_LIBS
	  to check if no library is required, instead of AC_CHECK_LIB.
	  [ruby-core:79368] [Bug #13175]
------------------------------------------------------------------------
r58626 | nagachika | 2017-05-09 23:48:49 +0900 (Tue, 09 May 2017) | 6 lines

merge revision(s) 57180: [Backport #13247]

	memory_status.c: support old Mac OS

	* ext/-test-/memory_status/memory_status.c (read_status): use
	  TASK_BASIC_INFO instead of MACH_TASK_BASIC_INFO on old Mac OS.
------------------------------------------------------------------------
r58625 | nagachika | 2017-05-09 23:46:24 +0900 (Tue, 09 May 2017) | 11 lines

merge revision(s) 58453,58454: [Backport #13499]

	Fix space flag when Inf/NaN and width==3

	* sprintf.c (rb_str_format): while `"% 2f"` and `"% 4f"` result in
	  `" Inf"` and `" Inf"` respectively, `"% 3f"` results in
	  `"Inf"` (no space).
	Refactor "%f" % Inf/NaN

	* sprintf.c (rb_str_format): as for non-finite float, calculate
	  the exact needed size with the space flag.
------------------------------------------------------------------------
r58624 | nagachika | 2017-05-09 23:28:21 +0900 (Tue, 09 May 2017) | 6 lines

merge revision(s) 57359: [Backport #13442]

	uri/generic.rb: fix exception on non-IP format

	* lib/uri/generic.rb (URI::Generic#find_proxy): match IP address
	  no_proxy against resolved self IP address.  [Fix GH-1513]
------------------------------------------------------------------------
r58623 | nagachika | 2017-05-09 23:24:20 +0900 (Tue, 09 May 2017) | 11 lines

merge revision(s) 58370,58382: [Backport #13530]

	thread_win32.c: no GVL for interrupt_event

	* thread_win32.c (w32_wait_events): do not acquire GVL, to fix
	  deadlock at read/close race condition.  instead, just ignore
	  interrupt_event if it is closed.
	thread_win32.c: fix index

	* thread_win32.c (w32_wait_events): fix wait object index in the
	  case of interrupt_event is not usable.
------------------------------------------------------------------------
r58622 | nagachika | 2017-05-09 23:21:37 +0900 (Tue, 09 May 2017) | 6 lines

merge revision(s) 58534: [Backport #13533]

	nogvl_wait_for_single_fd must wait as its name

	poll(fds, n, 0) mean no timeout and immediately return. If you want to
	wait something, you need to use -1 instead.
------------------------------------------------------------------------
r58620 | nagachika | 2017-05-09 23:11:14 +0900 (Tue, 09 May 2017) | 19 lines

merge revision(s) 57531,57532,57533,57537: [Backport #13191]

	pty/shl.rb: update [ci skip]

	* sample/pty/shl.rb: stop writer loop when the child exited.
	  PTY::ChildExited no longer raises asynchronously since r20298.
	  [ruby-dev:49974] [Bug #13191]
	pty/shl.rb: update [ci skip]

	* sample/pty/shl.rb: use io/console instead of stty.
	  [ruby-dev:49974] [Bug #13191]
	pty/shl.rb: update [ci skip]

	* sample/pty/shl.rb: do not manage array length separately.
	  [ruby-dev:49974] [Bug #13191]
	pty/shl.rb: update [ci skip]

	* sample/pty/shl.rb: leap exited child process.
	  [ruby-dev:49974] [Bug #13191]
------------------------------------------------------------------------
r58619 | nagachika | 2017-05-09 23:09:44 +0900 (Tue, 09 May 2017) | 6 lines

merge revision(s) 58084: [Backport #13361]

	configure.in: syscall is deprecated on macOS

	* configure.in: syscall is no longer supported on macOS since
	  10.12.  [ruby-core:80300] [Bug #13361]
------------------------------------------------------------------------
r58445 | nagachika | 2017-04-22 16:29:01 +0900 (Sat, 22 Apr 2017) | 7 lines

merge revision(s) 58323,58324:

	Merge json-2.0.4.

	  * https://github.com/flori/json/releases/tag/v2.0.4
	  * https://github.com/flori/json/blob/09fabeb03e73ed88dc8ce8f19d76ac59e51dae20/CHANGES.md#2017-03-23-204
	Use `assert_raise` instead of `assert_raises`.
------------------------------------------------------------------------
r58444 | nagachika | 2017-04-22 16:20:22 +0900 (Sat, 22 Apr 2017) | 1 line

bump teeny version to 2.4.2
------------------------------------------------------------------------
r58079 | naruse | 2017-03-24 23:06:24 +0900 (Fri, 24 Mar 2017) | 3 lines

merge revision(s) 58078:

	export_changelog must specify the branch's url
------------------------------------------------------------------------
r58052 | naruse | 2017-03-22 14:54:22 +0900 (Wed, 22 Mar 2017) | 11 lines

merge revision(s) 58040,58041:

	stringio.c: check character code

	* ext/stringio/stringio.c (strio_ungetc): check if the character
	  code is valid in the encoding.  reported by Ahmad Sherif
	  (ahmadsherif) at https://hackerone.com/reports/209593.
	stringio.c: check range

	* ext/stringio/stringio.c (strio_ungetc): raise RangeError instead
	  of TypeError at too big value, as well as IO#ungetc.
------------------------------------------------------------------------
r58047 | naruse | 2017-03-22 01:22:21 +0900 (Wed, 22 Mar 2017) | 2 lines

Bump up version to 2.4.1

------------------------------------------------------------------------
r58046 | naruse | 2017-03-21 23:11:42 +0900 (Tue, 21 Mar 2017) | 8 lines

merge revision(s) 58042: [Backport #13339]

	string.c: use the usable size

	* string.c (rb_str_change_terminator_length): when called after
	  the content has been copied, old terminator length no longer
	  makes sense.  use the whole usable size instead of capacity
	  without terminator.  [ruby-core:80257] [Bug #13339]
------------------------------------------------------------------------
r58045 | naruse | 2017-03-21 23:04:23 +0900 (Tue, 21 Mar 2017) | 20 lines

merge revision(s) 57192,57464,58016,58018,58019: [Backport #12705]

	[Bug #12705]
	add a ticket number.

	test_lambda.rb: refine test

	* test/ruby/test_lambda.rb (test_lambda_as_iterator): refine a
	  test for the intention of the original report.
	  [ruby-core:61340] [Bug #9605]
	test_lambda.rb: remove duplcate tests
	vm_args.c: arity check of lambda

	* vm_eval.c (rb_yield_lambda): new function which yields an array
	  to a proc and splat to a lambda.  mainly for Enumerable only.

	* vm_args.c (setup_parameters_complex): remove special lambda
	  splatting for [Bug #9605].  [ruby-core:77065] [Bug #12705]

	* vm_insnhelper.c (vm_callee_setup_block_arg): ditto.
------------------------------------------------------------------------
r58022 | naruse | 2017-03-19 23:29:22 +0900 (Sun, 19 Mar 2017) | 6 lines

merge revision(s) 58015: [Backport #13325]

	vm_args.c: pass block

	* vm_args.c (refine_sym_proc_call): pass block to the method when
	  using refinements.  [ruby-core:80219] [Bug #13325]
------------------------------------------------------------------------
r58013 | naruse | 2017-03-18 21:02:27 +0900 (Sat, 18 Mar 2017) | 7 lines

merge revision(s) 57972: [Backport #13198]

	Fix bug of Tempfile#size if nothing is written [Bug #13198]

	* lib/tempfile.rb (Tempfile#size): Fix its behavior when nothing
	  is written. Tempfile#size should return 0 in this case.
	  The patch is from nobu <nobu@ruby-lang.org>.
------------------------------------------------------------------------
r58003 | naruse | 2017-03-17 16:06:50 +0900 (Fri, 17 Mar 2017) | 17 lines

merge revision(s) 57968,57969,57970: [Backport #13313]

	thread.c: thread_do_start

	* thread.c (thread_do_start): extract from a macro in
	  thread_start_func_2 for debugger.
	thread.c: Thread.start with Symbol

	* thread.c (thread_do_start): fix segfault at start with Symbol.
	  proc created by Symbol#to_proc does not have environment unless
	  using refinements.  [ruby-core:80147] [Bug #13313]
	Fiber also has same issue. [Bug #13313]

	* thread.c (rb_vm_proc_local_ep): added.

	* cont.c (rb_fiber_start): use rb_vm_proc_local_ep().

------------------------------------------------------------------------
r58002 | naruse | 2017-03-17 13:44:13 +0900 (Fri, 17 Mar 2017) | 6 lines

merge revision(s) 57956:

	Raise error if spec is nil

	With parallel test-all, the spec is sometimes nil.
	To debug it raise more detailed error.
------------------------------------------------------------------------
r58001 | naruse | 2017-03-17 13:36:49 +0900 (Fri, 17 Mar 2017) | 13 lines

merge revision(s) 57523,57998: [Backport #13322]

	test_gem.rb: exclude default gems

	* test/rubygems/test_gem.rb: check difference to exclude default
	  gems from the expected results.  [Feature #13186]
	Merge rubygems-2.6.11

	  This version fixed regression of rubygems-2.6.10.
	  https://github.com/rubygems/rubygems/pull/1856

	  See details of changelogs for 2.6.11 release:
	  https://github.com/rubygems/rubygems/blob/adfcf40502716080bd9cdfdd2e43bd4296872784/History.txt#L3
------------------------------------------------------------------------
r57959 | naruse | 2017-03-13 18:28:35 +0900 (Mon, 13 Mar 2017) | 10 lines

merge revision(s) 57948,57950: [Backport #13304]

	thread.c: rb_thread_fd_close [ci skip]

	* thread.c (rb_thread_fd_close): re-define only for abi-check,
	  abort if called.  [ruby-core:80078] [Bug #13304]
	thread.c: rb_thread_fd_close [ci skip]

	* thread.c (rb_thread_fd_close): remove deprecated. a couple of
	  external libraries used it.  [ruby-core:80078] [Bug #13304]
------------------------------------------------------------------------
r57957 | naruse | 2017-03-13 18:05:46 +0900 (Mon, 13 Mar 2017) | 6 lines

merge revision(s) 57603: [Backport #12997]

	Merge Onigmo 6.1.1

	* Support absent operator https://github.com/k-takata/Onigmo/issues/82
	* https://github.com/k-takata/Onigmo/blob/Onigmo-6.1.1/HISTORY
------------------------------------------------------------------------
r57954 | naruse | 2017-03-13 16:30:30 +0900 (Mon, 13 Mar 2017) | 33 lines

merge revision(s) 57410,57619,57621,57631,57634: [Backport #13150]

	Prevent GC by volatile [Bug #13150]

	test/ruby/test_marshal.rb test_context_switch (load) and test_gc (dump)
	are failed on FreeBSD 10.3 and gcc7 (FreeBSD Ports Collection) 7.0.0
	20170115 (experimental); RB_GC_GUARD looks not worked well.
	ruby.h: RB_GC_GUARD stronger than gcc7

	* include/ruby/ruby.h (RB_GC_GUARD): prevent guarded pointer from
	  optimization by using as an input to inline asm.
	ruby.h: remove comment

	* include/ruby/ruby.h (RB_GC_GUARD): remove comment unsupported by
	  Solaris AS.
	marshal.c: use hidden objects to allow recycling

	Hidden objects (klass == 0) are not visible to Ruby code invoked
	from other threads or signal handlers, so they can never be
	accessed from other contexts.  This makes it safe to call
	rb_gc_force_recycle on the object slot after releasing malloc
	memory.

	* marshal.c (rb_marshal_dump_limited): hide dump_arg and recycle when done
	  (rb_marshal_load_with_proc): hide load_arg and recycle when done
	  [ruby-core:79518]
	marshal.c: revert r57631 partially

	* marshal.c (rb_marshal_dump_limited): do not free dump_arg, which
	  may be dereferenced in check_dump_arg due to continuation, and
	  get rid of dangling pointers.

	* marshal.c (rb_marshal_load_with_proc): ditto for load_arg.
------------------------------------------------------------------------
r57953 | naruse | 2017-03-13 16:03:32 +0900 (Mon, 13 Mar 2017) | 10 lines

merge revision(s) 57269,57277:

	bignum.c: fix rb_cstr_parse_inum endp

	* bignum.c (rb_cstr_parse_inum): stores the address of the first
	  invalid character when str is too big or contains an underscore.
	bignum.c: unnecessary check

	* bignum.c (rb_cstr_parse_inum): remove unnecessary check.
	  successive sign is rejected by conv_digit.
------------------------------------------------------------------------
r57952 | naruse | 2017-03-13 15:58:19 +0900 (Mon, 13 Mar 2017) | 6 lines

merge revision(s) 57412: [Backport #13308]

	Update Rubygems 2.6.10

	 * https://github.com/rubygems/rubygems/commit/2ee5bf9fd3bd7649d3e244bc40107ff32070ef47
	 * https://github.com/rubygems/rubygems/commit/be510dd4097e65c6a256a6e173d6b724a3a96472
------------------------------------------------------------------------
r57945 | naruse | 2017-03-13 03:41:38 +0900 (Mon, 13 Mar 2017) | 8 lines

merge revision(s) 57767,57943: [Backport #10403]

	io.c: documentation for puts

	* io.c: [DOC] clarify that the 'record separator' between
	  arguments passed to 'puts' is always a newline.
	  Based on a patch by Mark Amery. [ruby-core:65801] [Misc #10403]
	* 2017-03-13
------------------------------------------------------------------------
r57941 | naruse | 2017-03-13 03:15:33 +0900 (Mon, 13 Mar 2017) | 66 lines

merge revision(s) 57469,57471,57472,57503,57508: [Backport #13299]

	io.c: recycle garbage on write

	* string.c (STR_IS_SHARED_M): new flag to mark shared mulitple times
	  (STR_SET_SHARED): set STR_IS_SHARED_M
	  (rb_str_tmp_frozen_acquire, rb_str_tmp_frozen_release): new functions
	  (str_new_frozen): set/unset STR_IS_SHARED_M as appropriate
	* internal.h: declare new functions
	* io.c (fwrite_arg, fwrite_do, fwrite_end): new
	  (io_fwrite): use new functions

	Introduce rb_str_tmp_frozen_acquire and rb_str_tmp_frozen_release
	to manage a hidden, frozen string.  Reuse one bit of the embed
	length for shared strings as STR_IS_SHARED_M to indicate a string
	has been shared multiple times.  In the common case, the string
	is only shared once so the object slot can be reclaimed immediately.

	minimum results in each 3 measurements. (time and size)

	Execution time (sec)
	name                            trunk   built
	io_copy_stream_write            0.682   0.254
	io_copy_stream_write_socket     1.225   0.751

	Speedup ratio: compare with the result of `trunk' (greater is better)
	name    built
	io_copy_stream_write            2.680
	io_copy_stream_write_socket     1.630

	Memory usage (last size) (B)
	name                            trunk           built
	io_copy_stream_write            95436800.000    6512640.000
	io_copy_stream_write_socket     117628928.000   7127040.000

	Memory consuming ratio (size) with the result of `trunk' (greater is better)
	name    built
	io_copy_stream_write            14.654
	io_copy_stream_write_socket     16.505
	string.c (rb_str_tmp_frozen_release): release embedded strings

	Handle the embedded case first, since we may have an embedded
	duplicate and non-embedded original string.

	* string.c (rb_str_tmp_frozen_release): handled embedded strings
	* test/ruby/test_io.rb (test_write_no_garbage): new test
	  [ruby-core:78898] [Bug #13085]
	io.c (rb_io_syswrite): avoid leaving garbage after write

	As with IO#write, IO#syswrite also generates garbage which can
	be harmful in hand-coded read-write loops.

	* io.c (swrite_arg, swrite_do, swrite_end): new
	  (rb_io_syswrite): use new functions to cleanup garbage
	  [ruby-core:78898] [Bug #13085]
	Add class name to assert messages
	io.c: remove rb_ensure usage for rb_str_tmp_frozen_* calls

	Using rb_ensure pessimizes the common case and makes the code
	more difficult to read and follow.  If we hit an exceptions
	during write, just let the GC handle cleanup as the exception
	is already bad for garbage.

	* io.c (io_fwrite): call rb_str_tmp_frozen{acquire,release} directly
	  (rb_io_syswrite): ditto
	  (fwrite_do, fwrite_end, swrite_do, swrite_end): remove
------------------------------------------------------------------------
r57940 | naruse | 2017-03-13 03:01:40 +0900 (Mon, 13 Mar 2017) | 11 lines

merge revision(s) 57811: [Backport #9829]

	docs for FileUtils.ln methods

	* lib/fileutils.rb: [DOC] add clarifying call-seq's for FileUtil.ln,
	  ln_s, and ln_sf, with better argument names for the created link and
	  link target.  Reported by Mike Vastola. [ruby-core:62532] [Bug #9829]

	* lib/fileutils.rb: [DOC] further improve descriptions of FileUtils.ln
	  and related methods; improve examples: relative links probably won't
	  work in other dir, avoid `include', use more generic homedir name.
------------------------------------------------------------------------
r57939 | naruse | 2017-03-13 03:01:22 +0900 (Mon, 13 Mar 2017) | 11 lines

merge revision(s) 57415,57463,57474:

	eval.c: copy special exception

	* eval.c (setup_exception): make unfrozen copy of special
	  exception before setting up a cause.
	reduce iterations for slower machines
	test_io.rb: separate a test

	* test/ruby/test_io.rb (test_closed_stream_in_rescue): run in a
	  separated process.
------------------------------------------------------------------------
r57938 | naruse | 2017-03-13 02:51:21 +0900 (Mon, 13 Mar 2017) | 7 lines

merge revision(s) 57427: [Backport #13030]

	skip T_IMEMO for VMDEBUG

	* vm_dump.c (vm_stack_dump_each): skip T_IMEMO object to display
	  for VMDEBUG=3. [Bug #13030]

------------------------------------------------------------------------
r57937 | naruse | 2017-03-13 02:26:03 +0900 (Mon, 13 Mar 2017) | 5 lines

merge revision(s) 57809: [Backport #13291]

	fix paren

	* string.c (str_byte_substr): fix misplaced parenthesis at r56155.
------------------------------------------------------------------------
r57936 | naruse | 2017-03-13 02:23:03 +0900 (Mon, 13 Mar 2017) | 7 lines

merge revision(s) 57741: [Backport #13254]

	disable critical-error-handler

	* win32/win32.c (rb_w32_sysinit): disable critical-error-handler
	  message box even on mswin, regardless of runtime DLL version.
	  [ruby-dev:49988] [Bug #13254]
------------------------------------------------------------------------
r57935 | naruse | 2017-03-13 02:22:20 +0900 (Mon, 13 Mar 2017) | 15 lines

merge revision(s) 57816,57817: [Backport #13292]

	fix UTF-32 valid_encoding?

	* enc/utf_32be.c (utf32be_mbc_enc_len): check arguments precisely.
	  [ruby-core:79966] [Bug #13292]

	* enc/utf_32le.c (utf32le_mbc_enc_len): ditto.

	* regenc.h (UNICODE_VALID_CODEPOINT_P): predicate for valid
	  Unicode codepoints.
	fix UTF-32 valid_encoding?

	* test/ruby/test_io_m17n.rb (TestIO_M17N#test_puts_widechar): do
	  not use invalid codepoint.  [ruby-core:79966] [Bug #13292]
------------------------------------------------------------------------
r57934 | naruse | 2017-03-13 02:14:38 +0900 (Mon, 13 Mar 2017) | 7 lines

merge revision(s) 57801: [Backport #13287]

	parse.y: remove trace

	* parse.y (reg_named_capture_assign_iter): do not insert trace
	  instructions before local variable assinments.  putobject is
	  expected at first.  [ruby-core:79940] [Bug #13287]
------------------------------------------------------------------------
r57933 | naruse | 2017-03-13 02:10:14 +0900 (Mon, 13 Mar 2017) | 6 lines

merge revision(s) 57802:

	string.c: [DOC] Fix a typo in String#dump

	[Fix GH-1531][ci skip]
	Author:    Alex Semyonov <alex@semyonov.us>
------------------------------------------------------------------------
r57932 | naruse | 2017-03-13 02:10:01 +0900 (Mon, 13 Mar 2017) | 2 lines

RbConfig::Limits is Ruby 2.5 feature

------------------------------------------------------------------------
r57931 | naruse | 2017-03-13 01:51:47 +0900 (Mon, 13 Mar 2017) | 17 lines

merge revision(s) 57797,57799,57800: [Backport #13289]

	string.c: fix integer overflow

	* string.c (rb_str_subpos): fix integer overflow which can happen
	  only when SHARABLE_MIDDLE_SUBSTRING is enabled.  incorpolate
	  https://github.com/mruby/mruby/commit/7db0786abdd243ba031e24683f
	string.c: fix integer overflow

	* string.c (str_byte_substr): fix another integer overflow which
	  can happen only when SHARABLE_MIDDLE_SUBSTRING is enabled.
	  [ruby-core:79951] [Bug #13289]

	string.c: negation of LONG_MIN

	* string.c (rb_str_update): do not use negation of LONG_MIN, which
	  is negative too.
------------------------------------------------------------------------
r57930 | naruse | 2017-03-13 01:31:18 +0900 (Mon, 13 Mar 2017) | 11 lines

merge revision(s) 57781:

	docs for IO.{write,read}

	* io.c: [DOC] improve docs for IO
	  * IO.{write,read}: fix errors (:open_args is not an array of
	    strings, it might include a perm or options hash argument;
	    IO.write has no length argument, drop corresponding statement),
	    improve formatting, call-seq, grammar.
	  * IO#sync=: remove unnecessary "produces no output".
	  * other improvements.
------------------------------------------------------------------------
r57929 | naruse | 2017-03-13 01:30:08 +0900 (Mon, 13 Mar 2017) | 7 lines

merge revision(s) 57780: [Backport #12975]

	docs for IO#print

	* io.c: [DOC] split documentation for IO#print into smaller paragraphs,
	  delete duplicate sentence, fix call-seq.
	  Based on a patch by Dario Daic. [ruby-core:78291] [Bug #12975]
------------------------------------------------------------------------
r57928 | naruse | 2017-03-13 01:29:47 +0900 (Mon, 13 Mar 2017) | 7 lines

merge revision(s) 57778,57779:

	string.c: [DOC] fix doc formatting for String#==, #===
	math.c: more accuracy

	* math.c (math_log10): calculate log10(2) for more accuracy.
	  [ruby-core:79907] [Bug #13279]
------------------------------------------------------------------------
r57927 | naruse | 2017-03-13 01:29:12 +0900 (Mon, 13 Mar 2017) | 6 lines

merge revision(s) 57777:

	rdoc for String class

	* lib/unicode_normalize.rb: [DOC] prevent a comment from
	  showing up in the class documentation for String.
------------------------------------------------------------------------
r57926 | naruse | 2017-03-13 01:28:42 +0900 (Mon, 13 Mar 2017) | 7 lines

merge revision(s) 57775: [Backport #13281]

	nodoc OptParse

	* lib/optparse.rb: [DOC] nodoc OptParse, introduced with r46126,
	  to avoid leaking of its documentation (OptionParser's docs) into
	  the class documentation of Object.  [ruby-core:79909] [Bug #13281]
------------------------------------------------------------------------
r57925 | naruse | 2017-03-13 01:27:45 +0900 (Mon, 13 Mar 2017) | 7 lines

merge revision(s) 57771:

	documentation for sort methods

	* array.c: [DOC] fix grammar in Array#sort, #sort!, #sort_by!,
	  move references below the code example, add a missing reference.
	* enum.c: [DOC] fix grammar in Enumerable#sort, #sort_by.
------------------------------------------------------------------------
r57924 | naruse | 2017-03-13 01:27:30 +0900 (Mon, 13 Mar 2017) | 7 lines

merge revision(s) 57770:

	enum.c: documentation for Enumerable#sort_by

	* enum.c: [DOC] improve structure of docs for Enumerable#sort_by,
	  adopt explanation of the comparison block from Array#sort_by,
	  drop mention of 1.8, fix typos.
------------------------------------------------------------------------
r57923 | naruse | 2017-03-13 01:23:09 +0900 (Mon, 13 Mar 2017) | 13 lines

merge revision(s) 57765: [Backport #13273]

	proc.c: documentation for Proc#{call,yield,[]}

	* proc.c: [DOC] fix and improve docs for Proc#{call,yield,[]}:

	  * change order of Document-method directives as workaround for an
	    RDoc rendering problem where the documentation for Proc#call displays
	    a "Document-method: []" code block.  [ruby-core:79887] [Bug #13273]
	  * add missing call-seq and example for Proc#yield
	  * remove pointless cross reference to Proc#yield
	  * update description for handling of extra or missing arguments,
	    improve examples and add cross reference to #lambda?
------------------------------------------------------------------------
r57922 | naruse | 2017-03-13 01:22:05 +0900 (Mon, 13 Mar 2017) | 6 lines

merge revision(s) 57763:

	fix for mingw64

	* util.c: define MINGW_HAS_SECURE_API for qsort_s on recent
	  mingw64.
------------------------------------------------------------------------
r57921 | naruse | 2017-03-13 01:21:43 +0900 (Mon, 13 Mar 2017) | 8 lines

merge revision(s) 57762: [Backport #13267]

	broken mingw

	* configure.in: check whether frexp and modf are broken.

	* include/ruby/win32.h (frexp, modf): ignore bad declarations when
	  compiling as C++.  [ruby-core:79859] [Bug #13267]
------------------------------------------------------------------------
r57920 | naruse | 2017-03-13 01:20:56 +0900 (Mon, 13 Mar 2017) | 4 lines

merge revision(s) 57761:

	[DOC] update doc.

------------------------------------------------------------------------
r57919 | naruse | 2017-03-13 01:20:09 +0900 (Mon, 13 Mar 2017) | 7 lines

merge revision(s) 57758: [Backport #13268]

	string.c: restore documentation for String#<<

	* string.c: [DOC] restore documentation for String#<<
	  which became undocumented with r56021; fix a typo.
	  [ruby-core:79865] [Bug #13268]
------------------------------------------------------------------------
r57918 | naruse | 2017-03-13 01:20:03 +0900 (Mon, 13 Mar 2017) | 13 lines

merge revision(s) 57751,57753,57755:

	fileutils.rb: improve rdoc for FileUtils

	* lib/fileutils.rb: [DOC] fix invalid example code to make it
	  syntax highlighted, fix rdoc for lists, nodoc internal methods,
	  avoid a dangerous example.
	hash.c: [DOC] fix book title in example
	struct.c: improve rdoc for Struct

	* struct.c: [DOC] improve examples for ::new, improve #dig example,
	  simplify #select example, use consistent style for return values,
	  fix typos and example code style, remove duplicate cross reference.
------------------------------------------------------------------------
r57917 | naruse | 2017-03-13 01:18:06 +0900 (Mon, 13 Mar 2017) | 11 lines

merge revision(s) 57737: [Backport #13225]

	date_core.c: expand docs for Date shifting

	* ext/date/date_core.c: [DOC] expand docs for Date shifting

	  * add examples for Date#>> and Date#<< that clarify some edge cases
	  * add examples for Date#next_year and Date#prev_year
	  * add cross references to Date#>> and Date#<<

	  [ruby-core:79584] [Bug #13225]
------------------------------------------------------------------------
r57916 | naruse | 2017-03-13 00:51:23 +0900 (Mon, 13 Mar 2017) | 9 lines

merge revision(s) 57735: [Backport #13148]

	Fix doc for Hash#dig and Struct#dig

	* hash.c (rb_hash_dig): [DOC] correct argument name
	  in method description; fix formatting in examples.
	* struct.c (rb_struct_dig): ditto.

	[ruby-core:79221] [Bug #13148]
------------------------------------------------------------------------
r57915 | svn | 2017-03-13 00:02:31 +0900 (Mon, 13 Mar 2017) | 1 line

* 2017-03-13
------------------------------------------------------------------------
r57914 | naruse | 2017-03-13 00:02:30 +0900 (Mon, 13 Mar 2017) | 7 lines

merge revision(s) 57589: [Backport #13205]

	parallel.rb: fix intervention

	* test/lib/test/unit/parallel.rb (_report): send a response and a
	  newline atomically, to get rid of intervention with "p" which
	  runs in a separate thread.
------------------------------------------------------------------------
r57913 | naruse | 2017-03-12 23:57:21 +0900 (Sun, 12 Mar 2017) | 16 lines

merge revision(s) 57255,57256,57257: [Backport #13111]

	forwardable.rb: use defined?

	* lib/forwardable.rb (_delegator_method): use defined? operator
	  instead of binding and calling unbound Kernel#respond_to?.  a
	  remedy for an performance bottleneck.
	forwardable.rb: use defined?

	* lib/forwardable.rb (_delegator_method): use defined? operator
	  instead of binding and calling unbound Kernel#respond_to?.  a
	  remedy for an performance bottleneck.
	forwardable.rb: fix branches

	* lib/forwardable.rb (instance_delegate, single_delegate): fix
	  inverted branches.
------------------------------------------------------------------------
r57912 | naruse | 2017-03-12 23:39:18 +0900 (Sun, 12 Mar 2017) | 7 lines

merge revision(s) 57717: [Backport #13253]

	parse.y: indent at invalid identifier

	* parse.y (parser_heredoc_identifier): set indent only when valid
	  identifier, not to dedent non-existent contents later.
	  [ruby-core:79772] [Bug #13253]
------------------------------------------------------------------------
r57911 | naruse | 2017-03-12 23:18:02 +0900 (Sun, 12 Mar 2017) | 10 lines

merge revision(s) 57688,57689: [Backport #13242]

	rational.c: infinity in power

	* rational.c (nurat_expt): return Infinity due to overflow.
	  [ruby-core:79686] [Bug #13242]:
	rational.c: infinity in power

	* rational.c (nurat_expt): return 0 due to overflow.
	  [ruby-core:79686] [Bug #13242]:
------------------------------------------------------------------------
r57910 | naruse | 2017-03-12 23:06:33 +0900 (Sun, 12 Mar 2017) | 14 lines

merge revision(s) 57665: [Backport #13229]

	extension.rdoc: add document title

	* doc/extension.rdoc, doc/extension.ja.rdoc: [DOC]
	  add title and adapt subheading levels.

	* doc/extension.rdoc: [DOC] fix subheading level of section
	  about "Ruby Constants That Can Be Accessed From C".

	* doc/extension.ja.rdoc: [DOC] add missing subheading.

	[ruby-core:79590] [Bug #13229]
	Author:    Marcus Stollsteimer <sto.mar@web.de>
------------------------------------------------------------------------
r57909 | naruse | 2017-03-12 23:03:16 +0900 (Sun, 12 Mar 2017) | 7 lines

merge revision(s) 57660: [Backport #13234]

	regparse.c: initialize return values

	* regparse.c (parse_char_class): initialize return values before
	  depth limit check.  returned values will be freed in callers
	  regardless the error.  [ruby-core:79624] [Bug #13234]
------------------------------------------------------------------------
r57907 | naruse | 2017-03-12 22:46:55 +0900 (Sun, 12 Mar 2017) | 7 lines

merge revision(s) 57655: [Backport #13227]

	vm_insnhelper.c: super to module in refinement

	* vm_insnhelper.c (vm_call_zsuper): method defined in module in
	  refinement is not callable as-is.  dispatch again.
	  [ruby-core:79588] [Bug #13227]
------------------------------------------------------------------------
r57906 | naruse | 2017-03-12 21:55:00 +0900 (Sun, 12 Mar 2017) | 4 lines

merge revision(s) 57595: [Backport #8996]

	check thread deadness correctly.

------------------------------------------------------------------------
r57905 | naruse | 2017-03-12 17:09:45 +0900 (Sun, 12 Mar 2017) | 9 lines

merge revision(s) 57584: [Backport #13202]

	[DOC] Update an obsolete example for slice_before.

	The argument for Enumerable#slice_before is is removed at Ruby 2.3.

	Reported by Shyouhei Urabe.  [Bug #13202]


------------------------------------------------------------------------
r57904 | naruse | 2017-03-12 17:04:28 +0900 (Sun, 12 Mar 2017) | 15 lines

merge revision(s) 57549: [Backport #13193]

	date_core.c: [DOC] revise docs [ci skip]

	* fix malformed rdoc for Date#today, Date._strptime,
	  and DateTime._strptime
	* add code examples for Date#<< and Date#>> to demonstrate
	  that different dates can result in the same return value
	* use Date::ITALY in call-seq instead of only ITALY
	* fix some copy/paste mistakes where Date should be DateTime
	* fix various errors and grammar
	* fix cross references and formatting

	[ruby-core:79433] [Bug #13193]
	Author:    Marcus Stollsteimer <sto.mar@web.de>
------------------------------------------------------------------------
r57903 | naruse | 2017-03-12 17:02:52 +0900 (Sun, 12 Mar 2017) | 8 lines

merge revision(s) 57543: [Backport #13194]

	rbinstall.rb: default umask

	* tool/rbinstall.rb: revert r49841 and default umask to just
	  prohibit all from writing.  symlink(2) has no argument to set
	  permissions but is affected by umask.
	  [ruby-dev:49975] [Bug #13194]
------------------------------------------------------------------------
r57902 | naruse | 2017-03-12 17:01:46 +0900 (Sun, 12 Mar 2017) | 7 lines

merge revision(s) 57539: [Backport #11752]

	rational.c: fix rdoc [ci skip]

	* rational.c (rb_rational_plus): [DOC] fix an example.
	  A patch by Trygve Flathen <at.ruby-lang AT flathen.net> in
	  [ruby-core:71755].  [Bug #11752]
------------------------------------------------------------------------
r57901 | naruse | 2017-03-12 16:54:43 +0900 (Sun, 12 Mar 2017) | 16 lines

merge revision(s) 57522: [Backport #13189]

	doc: restore class documentation for Struct

	* struct.c: restore class documentation for Struct
	  that disappeared with r46663.

	Due to r46663, the class documentation for Struct disappeared.
	(The revision inserted the definition of `InitVM_Struct` between
	the rdoc and the definition of `Init_Struct`.)

	The docs are rendered for 2.1: <https://docs.ruby-lang.org/en/2.1.0/Struct.html>,
	but not for later versions, see: <https://docs.ruby-lang.org/en/2.2.0/Struct.html>
	(Same for `ri` pages).

	[ruby-core:79416] [Bug #13189]
------------------------------------------------------------------------
r57900 | naruse | 2017-03-12 16:53:34 +0900 (Sun, 12 Mar 2017) | 44 lines

merge revision(s) 57690-57694:

	rational.c: infinity in power

	* rational.c (nurat_expt): return 0 due to overflow.
	  [ruby-core:79686] [Bug #13242]:
	------------------------------------------------------------------------
	r57690 | nobu | 2017-02-23 10:15:27 +0900 (Thu, 23 Feb 2017) | 7 lines

	[DOC] {read,write}_nonblock with exception: false

	Update docs to reflect EOF behavior change of read_nonblock and
	write_nonblock when using `exception: false`.

	[Fix GH-1527]
	Author:    Russell Davis <russell-stripe@users.noreply.github.com>
	------------------------------------------------------------------------
	r57691 | nobu | 2017-02-23 10:54:13 +0900 (Thu, 23 Feb 2017) | 11 lines

	socket.rb: [DOC] fix nonblock methods

	* ext/socket/lib/socket.rb (BasicSocket#recv_nonblock): fix
	  exception class and symbol.

	* ext/socket/lib/socket.rb (BasicSocket#recvmsg_nonblock): ditto.

	* ext/socket/lib/socket.rb (Socket#recvfrom_nonblock): fix the
	  method name.

	* ext/socket/lib/socket.rb (UDPSocket#recvfrom_nonblock): both.
	------------------------------------------------------------------------
	r57692 | nobu | 2017-02-23 11:00:28 +0900 (Thu, 23 Feb 2017) | 1 line

	[DOC] keyword argument _exception_
	------------------------------------------------------------------------
	r57693 | nobu | 2017-02-23 11:11:16 +0900 (Thu, 23 Feb 2017) | 1 line

	[DOC] mark up literals
	------------------------------------------------------------------------
	r57694 | nobu | 2017-02-23 11:40:17 +0900 (Thu, 23 Feb 2017) | 3 lines

	Revert r57690 except for read_nonblock

	https://github.com/ruby/ruby/pull/1527#issuecomment-281867551
------------------------------------------------------------------------
r57899 | naruse | 2017-03-12 16:52:32 +0900 (Sun, 12 Mar 2017) | 9 lines

merge revision(s) 57750:

	openssl: avoid segfault during running tests on Ubuntu trusty

	Import the commit 6693a549d673 ("test/test_pkey_ec: do not use dummy 0
	order", 2017-02-03) from upstream. Hopefully this will fix the segfault
	on RubyCI icc16-x64:

	  http://rubyci.org/logs/rubyci.s3.amazonaws.com/icc-x64/ruby-trunk/log/20170301T050002Z.fail.html.gz
------------------------------------------------------------------------
r57898 | naruse | 2017-03-12 16:51:35 +0900 (Sun, 12 Mar 2017) | 14 lines

merge revision(s) 57590,57591,57592: [Backport #13200]

	extmk.rb: split notes

	* ext/extmk.rb: split notes and echo per lines, for multiple lines
	  messages.  [ruby-core:79475] [Bug #13200]
	openssl: fix broken openssl check

	* ext/openssl/extconf.rb: check for broken OpenSSL only on mac OS.
	  [ruby-core:79475] [Bug #13200]
	openssl: fix broken openssl check

	* ext/openssl/deprecation.rb: check for broken OpenSSL only on mac
	  OS.  [ruby-core:79475] [Bug #13200]
------------------------------------------------------------------------
r57897 | naruse | 2017-03-12 16:46:26 +0900 (Sun, 12 Mar 2017) | 6 lines

merge revision(s) 57289: [Backport #13114]

	test_io_console.rb: fix of old CentOS5

	* test/io/console/test_io_console.rb (test_winsize): on old CentOS5
	  window size seems unable to be set across a pty.
------------------------------------------------------------------------
r57896 | naruse | 2017-03-12 16:46:13 +0900 (Sun, 12 Mar 2017) | 7 lines

merge revision(s) 57520: [Backport #13184]

	ruby.h: unused parameter

	* include/ruby/ruby.h (rb_scan_args_set): remove unused parameter
	  for more pedantic extension libraries.
	  [ruby-core:79399] [Feature #13184]
------------------------------------------------------------------------
r57895 | naruse | 2017-03-12 16:36:02 +0900 (Sun, 12 Mar 2017) | 10 lines

merge revision(s) 57517: [Backport #13190]

	doc: Fix error for escape sequences in string literals

	Backslash goes first in escape sequences, so it must be
	"any other character following a backslash is interpreted as ...",
	while the doc says "...followed by...".

	Author: Marcus Stollsteimer <sto.mar@web.de>
	[ruby-core:79418] [Bug #13190]
------------------------------------------------------------------------
r57894 | naruse | 2017-03-12 16:34:58 +0900 (Sun, 12 Mar 2017) | 7 lines

merge revision(s) 57492:

	test_queue.rb: fix portability

	* test/thread/test_queue.rb (test_queue_with_trap): fix
	  portability.  use SIGINT instead of SIGUSR2 which is supported
	  on not all platforms.
------------------------------------------------------------------------
r57893 | naruse | 2017-03-12 16:34:42 +0900 (Sun, 12 Mar 2017) | 5 lines

merge revision(s) 57515: [Backport #13169]

	lib/ostruct.rb: Fix returned value of each_pair.

	From a patch by Marcus Stollsteimer. [Fixes #13169]
------------------------------------------------------------------------
r57885 | naruse | 2017-03-12 04:18:45 +0900 (Sun, 12 Mar 2017) | 10 lines

merge revision(s) 57510,57511: [Backport #13176]

	eval.c: hide internal objects

	* eval.c (rb_ensure): veil internal exception objects not to leak
	  in ensure functions.  [ruby-core:79371] [Bug #13176]
	ensured.c: fix conflict

	* ext/-test-/exception/ensured.c (exc_raise): get rid of conflict
	  with raise(2) in the standard.  [ruby-core:79371] [Bug #13176]
------------------------------------------------------------------------
r57884 | naruse | 2017-03-12 04:06:22 +0900 (Sun, 12 Mar 2017) | 6 lines

merge revision(s) 57483:

	Describe about RUBY_CODESIGN

	With RUBY_CODESIGN people can avoid pushing many OK button of firewall
	dialogs on macOS through test-all.
------------------------------------------------------------------------
r57882 | naruse | 2017-03-12 03:59:50 +0900 (Sun, 12 Mar 2017) | 3 lines

merge revision(s) 57165:

	Add ruby_2_4 branch to test on travis [skip ci]
------------------------------------------------------------------------
r57881 | naruse | 2017-03-12 03:59:22 +0900 (Sun, 12 Mar 2017) | 26 lines

merge revision(s) 57482: [Backport #13080] [Backport #13170]

	openssl: import v2.0.3

	Import Ruby/OpenSSL 2.0.3. Only bugfixes. The full commit log since
	2.0.2 (imported at r57146) can be found at:

	  https://github.com/ruby/openssl/compare/v2.0.2...v2.0.3

	----------------------------------------------------------------
	Corey Bonnell (1):
	      Fix for ASN1::Constructive 'each' implementation

	Kazuki Yamaguchi (10):
	      Fix build with static OpenSSL libraries on Windows
	       ([ruby-core:78878] [Bug #13080])
	      Merge pull request #96 from CBonnell/master
	      Merge branch 'topic/windows-static-linking-without-pkg-config' into maint
	      appveyor.yml: update OpenSSL version to 1.0.2j
	      buffering: fix typo in doc
	      test/envutil: fix assert_raise_with_message
	      x509: fix OpenSSL::X509::Name#eql?
	       ([ruby-core:79310] [Bug #13170])
	      ruby-openssl-docker: update versions of Ruby and OpenSSL
	      .travis.yml: test with Ruby 2.4
	      Ruby/OpenSSL 2.0.3
------------------------------------------------------------------------
r57880 | naruse | 2017-03-12 03:46:17 +0900 (Sun, 12 Mar 2017) | 5 lines

merge revision(s) 57480:

	mkmf.rb: message format string

	* lib/mkmf.rb (checking_for): message needs format string.
------------------------------------------------------------------------
r57879 | naruse | 2017-03-12 03:45:34 +0900 (Sun, 12 Mar 2017) | 17 lines

merge revision(s) 57477,57478,57479: [Backport #12405]

	use TRUE/FALSE.

	define rb_thread_sleep_deadly_allow_spurious_wakeup().

	* thread.c, thread_sync.c: define new function
	  rb_thread_sleep_deadly_allow_spurious_wakeup() and use it instead of
	  using sleep_forever() directly.

	allow Queue operation in trap.

	* thread_sync.c: allow spurious wakeup to check Queue status just after trap.
	  [Bug #12405]

	* test/thread/test_queue.rb: add a test for it.

------------------------------------------------------------------------
r57878 | naruse | 2017-03-12 03:16:14 +0900 (Sun, 12 Mar 2017) | 7 lines

merge revision(s) 57437:

	leakchecker.rb: get rid of uninitialized Tempfile

	* test/lib/leakchecker.rb (LeakChecker#find_tempfiles): get rid of
	  errors on uninitialized Tempfile, which can be left when
	  Dir.tmpdir failed or by Tempfile.allocate.
------------------------------------------------------------------------
r57877 | naruse | 2017-03-12 03:15:50 +0900 (Sun, 12 Mar 2017) | 5 lines

merge revision(s) 57436:

	enum.c: write barrier

	* enum.c (rb_nmin_run): set the class with write barrier.
------------------------------------------------------------------------
r57876 | naruse | 2017-03-12 03:11:06 +0900 (Sun, 12 Mar 2017) | 11 lines

merge revision(s) 57434: [Backport #13161]

	Enumerable#{min,min_by,max,max_by} [ci skip]

	* enum.c: [DOC] Enumerable#{min,min_by,max,max_by} return a sorted
	  array when +n+ argument is used.

	* enum.c: Small typo : minimum -> maximum

	[Bug #13161]
	Author:    Eric Duminil <eric.duminil@gmail.com>
------------------------------------------------------------------------
r57875 | naruse | 2017-03-12 03:10:55 +0900 (Sun, 12 Mar 2017) | 3 lines

merge revision(s) 57431:

	[DOC] Use Integer instead of Fixnum [ci skip]
------------------------------------------------------------------------
r57874 | naruse | 2017-03-12 03:09:45 +0900 (Sun, 12 Mar 2017) | 8 lines

merge revision(s) 57428:

	Add document for lib/rss/atom.rb

	[fix GH-1520]

	Patch by Tsehau Chao. Thanks!!!

------------------------------------------------------------------------
r57873 | naruse | 2017-03-12 03:07:38 +0900 (Sun, 12 Mar 2017) | 6 lines

merge revision(s) 57423:

	Fix function name for DBM on extension document.

	  Patch by Yuji Yaginuma, @y-yagi <yuuji.yaginuma@gmail.com>
	  [ci skip][fix GH-1519]
------------------------------------------------------------------------
r57872 | naruse | 2017-03-12 03:07:19 +0900 (Sun, 12 Mar 2017) | 6 lines

merge revision(s) 57422: [Backport #13158]

	io.c: close before wait

	* io.c (io_close_fptr): notify then close, and wait for other
	  threads before free fptr.  [ruby-core:79262] [Bug #13158]
------------------------------------------------------------------------
r57871 | naruse | 2017-03-12 02:56:02 +0900 (Sun, 12 Mar 2017) | 5 lines

merge revision(s) 57421:

	[DOC] Add empty example to enum.all? and any?

	[ci skip]
------------------------------------------------------------------------
r57870 | naruse | 2017-03-12 02:55:02 +0900 (Sun, 12 Mar 2017) | 5 lines

merge revision(s) 57411: [Backport #13147]

	Fix typo of URI#escape [Bug #13147]

	patched by Steve Hill <sghill.dev@gmail.com>
------------------------------------------------------------------------
r57869 | naruse | 2017-03-12 02:51:05 +0900 (Sun, 12 Mar 2017) | 7 lines

merge revision(s) 57407: [Backport #13145]

	object.c: no TypeError at Symbol

	* object.c (special_object_p): uninterned Symbol also should not
	  raise a TypeError but return itself instead, as well as interned
	  Symbols.  [ruby-core:79216] [Bug #13145]
------------------------------------------------------------------------
r57868 | naruse | 2017-03-12 02:45:18 +0900 (Sun, 12 Mar 2017) | 6 lines

merge revision(s) 57406: [Backport #13149]

	csv.rb: fix field_size_limit check

	* lib/csv.rb (CSV#shift): the last column is an Array in extended
	  column since r55985.  [ruby-dev:49964] [Bug #13149]
------------------------------------------------------------------------
r57867 | naruse | 2017-03-12 02:40:39 +0900 (Sun, 12 Mar 2017) | 8 lines

merge revision(s) 57405:

	error.c: fixed doc [ci skip]

	* error.c (exc_message): fixed doc regarding the presence of
	  to_str.  [Fix GH-1517]

	Author:    Marc Gauthier <marcg.gauthier@gmail.com>
------------------------------------------------------------------------
r57866 | naruse | 2017-03-12 02:40:32 +0900 (Sun, 12 Mar 2017) | 6 lines

merge revision(s) 57390:

	Hash#fetch: fix grammar in documentation.

	[Fix GH-1515][ci skip]
	Author:    Alyssa Ross <hi+services.github@alyssa.is>
------------------------------------------------------------------------
r57865 | naruse | 2017-03-12 02:37:46 +0900 (Sun, 12 Mar 2017) | 3 lines

merge revision(s) 57375:

	More description about the protected attribute of a method
------------------------------------------------------------------------
r57864 | naruse | 2017-03-12 02:35:03 +0900 (Sun, 12 Mar 2017) | 5 lines

merge revision(s) 57374: [Backport #13135]

	string.c: rindex(//) should set $~.

	This seems a bug introduced by r520 (1.4.0).  [ruby-core:79110] [Bug #13135]
------------------------------------------------------------------------
r57863 | naruse | 2017-03-12 02:28:49 +0900 (Sun, 12 Mar 2017) | 5 lines

merge revision(s) 57372:

	Fix documentation of options for all of methods in FileUtils.

	Patch by galia traub( @galiat ). [Fix GH-1510][ci skip]
------------------------------------------------------------------------
r57862 | naruse | 2017-03-12 02:22:39 +0900 (Sun, 12 Mar 2017) | 6 lines

merge revision(s) 57362: [Backport #13096]

	vm_method.c: resolve refined method to undef

	* vm_method.c (rb_undef): resolve the method entry which refines a
	  prepended method entry.  [ruby-core:78944] [Bug #13096]
------------------------------------------------------------------------
r57861 | naruse | 2017-03-12 02:17:23 +0900 (Sun, 12 Mar 2017) | 6 lines

merge revision(s) 57360: [Backport #12884]

	class.c: non-keyword hash class

	* class.c (rb_extract_keywords): keep the class of non-keyword
	  elements hash as the original.  [ruby-core:77813] [Bug #12884]
------------------------------------------------------------------------
r57860 | naruse | 2017-03-12 02:10:01 +0900 (Sun, 12 Mar 2017) | 11 lines

merge revision(s) 57352: [Backport #13132]

	doc: improve documentation for Binding [ci skip]

	* remove explicit return from code examples
	* grammar fixes
	* other small fixes

	Patch by: Marcus Stollsteimer <sto.mar@web.de>

	[ruby-core:79082] [Bug #13132]
------------------------------------------------------------------------
r57859 | naruse | 2017-03-12 02:09:43 +0900 (Sun, 12 Mar 2017) | 9 lines

merge revision(s) 57335:

	s/SaveStringValue/SafeStringValue/

	Fix a typo in extension.rdoc.

	Signed-off-by: Akira Matsuda <ronnie@dio.jp>

	closes #1512
------------------------------------------------------------------------
r57858 | naruse | 2017-03-12 02:07:53 +0900 (Sun, 12 Mar 2017) | 11 lines

merge revision(s) 57317,57318:

	error.c: moved

	* error.c (preface_dump, postscript_dump): moved from
	  rb_vm_bugreport to place the last important message at the very
	  last after [NOTE].
	error.c: moved

	* error.c (preface_dump, postscript_dump): CrashReporter directory
	  was used before Mac OS X 10.6.
------------------------------------------------------------------------
r57857 | naruse | 2017-03-12 02:06:18 +0900 (Sun, 12 Mar 2017) | 6 lines

merge revision(s) 57315:

	vm_dump.c: postscript_dump

	* vm_dump.c (postscript_dump): mention crash report log twice
	  because important.
------------------------------------------------------------------------
r57856 | naruse | 2017-03-12 01:44:40 +0900 (Sun, 12 Mar 2017) | 7 lines

merge revision(s) 57305: [Backport #13114] [Backport #13120]

	variable.c: fix the condition to cache

	* variable.c (rb_const_set): fix the condition to cache the class
	  path and cache permanent or temporary path corresponding to the
	  outer klass.  [ruby-core:79039] [Bug #13120]
------------------------------------------------------------------------
r57855 | naruse | 2017-03-12 01:38:53 +0900 (Sun, 12 Mar 2017) | 14 lines

merge revision(s) 57302,57303,57304: [Backport #13119]

	string.c: block for scrub with ASCII-incompatible

	* string.c (rb_enc_str_scrub): honor the given block with
	  ASCII-incompatible encoding.  [ruby-core:79039] [Bug #13120]
	string.c: yield invalid part

	* string.c (rb_enc_str_scrub): yield the invalid part only with
	  ASCII-incompatible.  [ruby-core:79039] [Bug #13120]
	string.c: replacement and block

	* string.c (rb_enc_str_scrub): only one of replacement and block
	  is allowed.  [ruby-core:79038] [Bug #13119]
------------------------------------------------------------------------
r57854 | naruse | 2017-03-12 01:29:51 +0900 (Sun, 12 Mar 2017) | 10 lines

merge revision(s) 57300,57368: [Backport #12613]

	compile.c: check compile

	* compile.c (iseq_compile_each): check if sub nodes succeeded.
	  [ruby-core:76531] [Bug #12613]
	compile.c: check err_info

	* compile.c (iseq_setup): bail out if any errors found.
	  [ruby-core:76531] [Bug #12613]
------------------------------------------------------------------------
r57853 | naruse | 2017-03-12 01:24:17 +0900 (Sun, 12 Mar 2017) | 7 lines

merge revision(s) 57293: [Backport #13107]

	vm_insnhelper.c: block argument at tailcall

	* vm_insnhelper.c (vm_call_iseq_setup_tailcall): check interrupts
	  after set up the new frame, not the passed block to be clobbered
	  by invoked finalizers and so on.  [ruby-core:78981] [Bug #13107]
------------------------------------------------------------------------
r57850 | naruse | 2017-03-12 00:03:50 +0900 (Sun, 12 Mar 2017) | 8 lines

merge revision(s) 57283,57284: [Backport #13113]

	benchmarks for [Bug #13113] [ci skip]
	variable.c: resolve permanent name only

	* variable.c (rb_const_set): resolve and cache class name
	  immediately only if the outer class/module has the name,
	  otherwise just set the ID.  [ruby-core:79007] [Bug #13113]
------------------------------------------------------------------------
r57849 | naruse | 2017-03-11 23:59:43 +0900 (Sat, 11 Mar 2017) | 10 lines

merge revision(s) 57280,57282: [Backport #13112]

	console.c: OOB access

	* ext/io/console/console.c (console_set_winsize): fix
	  out-of-bounds access.  [ruby-core:79004] [Bug #13112]
	console.c: unpaired size

	* ext/io/console/console.c (console_set_winsize): reject unpaired
	  pixel size.
------------------------------------------------------------------------
r57848 | naruse | 2017-03-11 23:48:04 +0900 (Sat, 11 Mar 2017) | 11 lines

merge revision(s) 57278,57279: [Backport #12855]

	fix optimization for hash aset/aref with fstring

	Patch by Eric Wong [ruby-core:78797].
	I don't like the idea of making insns.def any bigger to support
	a corner case, and "test_hash_aref_fstring_identity" shows
	how contrived this is.

	[ruby-core:78783] [Bug #12855]
	adjust indent [ci skip]
------------------------------------------------------------------------
r57847 | naruse | 2017-03-11 23:25:54 +0900 (Sat, 11 Mar 2017) | 8 lines

merge revision(s) 57240: [Backport #13090]

	vm.c: fix return in lambda

	* vm.c (invoke_block_from_c_splattable): pass lambda-ness.

	* vm_eval.c (yield_under): invoke lambda proc properly.
	  [ruby-core:78917] [Bug #13090]
------------------------------------------------------------------------
r57846 | naruse | 2017-03-11 23:20:51 +0900 (Sat, 11 Mar 2017) | 7 lines

merge revision(s) 57236: [Backport #13089]

	rational.c: memory leak in gcd

	* rational.c (rb_gcd_gmp): fix memory leak.  patched by KISHIMOTO,
	  Makoto <ksmakoto AT dd.iij4u.or.jp> in [ruby-dev:49934].
	  [Bug #13089]
------------------------------------------------------------------------
r57845 | naruse | 2017-03-11 22:36:26 +0900 (Sat, 11 Mar 2017) | 6 lines

merge revision(s) 57205:

	cont.c: change fiber stack size doc [ci skip]

	It's many years since we had tiny 4KB fiber stacks :<
	point to the manpage instead for current, larger sizes.
------------------------------------------------------------------------
r57844 | naruse | 2017-03-11 22:35:55 +0900 (Sat, 11 Mar 2017) | 3 lines

merge revision(s) 57246: [Backport #13091]

	fix typo [Bug #13091]
------------------------------------------------------------------------
r57843 | naruse | 2017-03-11 22:35:22 +0900 (Sat, 11 Mar 2017) | 6 lines

merge revision(s) 57232: [Backport #13084]

	rational.c: fix for mathn

	* rational.c (read_num, read_rat_nos): dispatch by the type of numerator, for
	  mathn.  [ruby-core:78893] [Bug #13084]
------------------------------------------------------------------------
r57841 | naruse | 2017-03-11 22:23:42 +0900 (Sat, 11 Mar 2017) | 5 lines

merge revision(s) 57204:

        r57203 needs r57204.
	io.c: use io_close to close ARGF

------------------------------------------------------------------------
r57840 | naruse | 2017-03-11 22:03:46 +0900 (Sat, 11 Mar 2017) | 6 lines

merge revision(s) 57227: [Backport #13078]

	numeric.c: reduce fdiv

	* numeric.c (rb_int_fdiv_double): reduce first for more precise
	  result.  [ruby-core:78886] [Bug #13078]
------------------------------------------------------------------------
r57839 | naruse | 2017-03-11 22:02:37 +0900 (Sat, 11 Mar 2017) | 6 lines

merge revision(s) 57203:

	io.c: ARGF fd leak

	* io.c (argf_next_argv): fix leak of fd after breaking in #each
	  method.
------------------------------------------------------------------------
r57838 | naruse | 2017-03-11 22:02:01 +0900 (Sat, 11 Mar 2017) | 22 lines

merge revision(s) 57199,57202,57206,57224: [Backport #13076]

	io.c: fix race between read and close

	* io.c (io_fillbuf): fix race between read and close, in the case
	  the IO gets closed before the reading thread achieve the lock.
	  [ruby-core:78845] [Bug #13076]
	thread.c: fix race between read and close

	* thread.c (rb_thread_fd_close): wait until all threads using the
	  fd finish the operation, not to free the buffer in use.
	  [ruby-core:78845] [Bug #13076]
	revert a part of r57199

	* io.c (io_fillbuf): revert a part of r57199 because it broke IO#getch.
	  see also [Bug #13076]

	io.c: fix race between read and close

	* io.c (io_fillbuf): fix race between read and close and bail out
	  in the case the IO gets closed before the reading thread achieve
	  the lock.  [ruby-core:78845] [Bug #13076]
------------------------------------------------------------------------
r57837 | naruse | 2017-03-11 21:53:45 +0900 (Sat, 11 Mar 2017) | 6 lines

merge revision(s) 57198: [Backport #13073]

	parse.y: preserve cmdarg stack

	* parse.y (do_body): preserve cmdarg stack around do/end block.
	  [ruby-core:78837] [Bug #13073]
------------------------------------------------------------------------
r57834 | naruse | 2017-03-11 20:06:39 +0900 (Sat, 11 Mar 2017) | 6 lines

merge revision(s) 57194: [Backport #13074]

	vm_eval.c: Symbol#to_proc and instance_exec

	* vm_eval.c (yield_under): should evaluate the proc on the first
	  argument.  [ruby-core:78839] [Bug #13074]
------------------------------------------------------------------------
r57833 | naruse | 2017-03-11 19:44:13 +0900 (Sat, 11 Mar 2017) | 18 lines

merge revision(s) 57187,57234: [Backport #13075]

	pack.c: avoid returning uninitialized String

	Fix unpacking with 'b', 'B', 'h' and 'H' format. Do not return an
	uninitialized String to Ruby before filling the content bytes.
	Fixes r11175 ("pack.c (pack_unpack): execute block if given with
	unpacked value instead of creating an array", 2006-10-15).
	[ruby-core:78841] [Bug #13075]
	test/ruby/test_pack.rb: fix test case added by r57187

	The test case for String#unpack added by r57187 is not properly testing
	because the String will be filled after the block invocation.
	[ruby-core:78841] [Bug #13075]

	Thanks to nagachika for pointing this out:

  http://d.hatena.ne.jp/nagachika/20161226/ruby_trunk_changes_57184_57194#r57187
------------------------------------------------------------------------
r57832 | naruse | 2017-03-11 19:37:09 +0900 (Sat, 11 Mar 2017) | 5 lines

merge revision(s) 57179:

	bignum.c: precise fdiv

	* bignum.c (big_fdiv): more precise calculation.  [ruby-dev:49915]
------------------------------------------------------------------------
r57831 | naruse | 2017-03-11 19:28:14 +0900 (Sat, 11 Mar 2017) | 24 lines

merge revision(s) 57173-57175: [Backport #13068]

	------------------------------------------------------------------------
	r57173 | nobu | 2016-12-24 22:19:50 +0900 (Sat, 24 Dec 2016) | 4 lines

	compile.c: constify

	* compile.c (method_for_self): constify an argument of build
  function for VC6.
	------------------------------------------------------------------------
	r57174 | nobu | 2016-12-24 22:21:30 +0900 (Sat, 24 Dec 2016) | 4 lines

	hash.c: split long long literals

	* hash.c (prime1, prime2): split long long literals for platforms
  where LL suffix is not supported, e.g., VC6.
	------------------------------------------------------------------------
	r57175 | nobu | 2016-12-24 22:22:53 +0900 (Sat, 24 Dec 2016) | 4 lines

	regint.h: version for secure functions

	* regint.h (xvsnprintf): secure version functions are not
  supported on old VC.

------------------------------------------------------------------------
r57830 | naruse | 2017-03-11 19:17:35 +0900 (Sat, 11 Mar 2017) | 21 lines

merge revision(s) 57170-57172: [Backport #13066]

	test/unit.rb: restore parallel option

	* test/lib/test/unit.rb (_run_parallel): restore parallel option
  after retrying for --repeat-count option.
	------------------------------------------------------------------------
	r57170 | nobu | 2016-12-24 20:56:12 +0900 (Sat, 24 Dec 2016) | 1 line

	time.c: fix typo in value_insane_p
	------------------------------------------------------------------------
	r57171 | nobu | 2016-12-24 21:19:23 +0900 (Sat, 24 Dec 2016) | 1 line

	time.c: remove debug code
	------------------------------------------------------------------------
	r57172 | nobu | 2016-12-24 21:21:52 +0900 (Sat, 24 Dec 2016) | 4 lines

	time.c: fix type of usec2subsecx

	* time.c (usec2subsecx): fix return type, which is a numeric
  object but not a long int.  [ruby-dev:49912] [Bug #13066]
------------------------------------------------------------------------
r57163 | svn | 2016-12-24 01:03:40 +0900 (Sat, 24 Dec 2016) | 1 line

* 2016-12-24
------------------------------------------------------------------------
r57162 | naruse | 2016-12-24 01:03:39 +0900 (Sat, 24 Dec 2016) | 2 lines

v2.4.0p0

------------------------------------------------------------------------
r57161 | naruse | 2016-12-24 00:44:33 +0900 (Sat, 24 Dec 2016) | 1 line

Release branch of Ruby 2.4
------------------------------------------------------------------------
r57160 | naruse | 2016-12-23 23:54:04 +0900 (Fri, 23 Dec 2016) | 3 lines

Increase timeout

http://rubyci.org/logs/rubyci.s3.amazonaws.com/aix71_ppc/ruby-trunk/log/20161223T113301Z.fail.html.gz
------------------------------------------------------------------------
r57159 | nobu | 2016-12-23 12:22:36 +0900 (Fri, 23 Dec 2016) | 5 lines

assertions.rb: prepare_syntax_check

* test/lib/test/unit/assertions.rb (prepare_syntax_check): extract
  common preparation of arguments from assert_valid_syntax and
  assert_syntax_error.
------------------------------------------------------------------------
r57158 | nobu | 2016-12-23 12:22:35 +0900 (Fri, 23 Dec 2016) | 8 lines

assertions.rb: syntax check by iseq

* test/lib/test/unit/assertions.rb (assert_valid_syntax): use
  RubyVM::InstructionSequence.compile to get rid of executing the
  code, instead of catch&throw.  sample/trick2015/kinaba/entry.rb
  no longer raises an Invalid return.

* test/lib/test/unit/assertions.rb (assert_syntax_error): ditto.
------------------------------------------------------------------------
r57157 | nobu | 2016-12-23 09:05:40 +0900 (Fri, 23 Dec 2016) | 4 lines

time.c: inquire suspicious values

* time.c (time_arg): dump sec and subsec arguments if subsecx is
  insane.
------------------------------------------------------------------------
r57156 | nobu | 2016-12-23 08:20:00 +0900 (Fri, 23 Dec 2016) | 5 lines

test_modify_expand.rb: skip if no overflow

* test/-ext-/string/test_modify_expand.rb (test_integer_overflow):
  no longer happens on platforms where size_t is larger than long,
  e.g. 64bit windows, since r57122.
------------------------------------------------------------------------
r57155 | nobu | 2016-12-23 07:34:18 +0900 (Fri, 23 Dec 2016) | 1 line

time.c: inquire suspicious values
------------------------------------------------------------------------
r57154 | nobu | 2016-12-23 07:16:19 +0900 (Fri, 23 Dec 2016) | 4 lines

string.c: suppress a warning

* string.c (rb_str_casecmp_p): [DOC] use Unicode escape form to
  get rid of warning C4819 by Microsoft Visual C++.
------------------------------------------------------------------------
r57153 | svn | 2016-12-23 05:58:55 +0900 (Fri, 23 Dec 2016) | 1 line

* 2016-12-23
------------------------------------------------------------------------
r57152 | nobu | 2016-12-23 05:58:55 +0900 (Fri, 23 Dec 2016) | 1 line

get rid of implicit signedness conversions
------------------------------------------------------------------------
r57151 | yui-knk | 2016-12-22 19:29:40 +0900 (Thu, 22 Dec 2016) | 4 lines

test_float.rb: add test cases for Float#round

* test_float.rb: add test cases for Float#round with
  half nil. Follow up r57130.
------------------------------------------------------------------------
r57150 | naruse | 2016-12-22 18:44:30 +0900 (Thu, 22 Dec 2016) | 3 lines

suppress warning: implicit conversion changes signedness

It causes [Bug #13060]
------------------------------------------------------------------------
r57149 | rhe | 2016-12-22 13:40:28 +0900 (Thu, 22 Dec 2016) | 4 lines

io.c: [DOC] update outdated documentation of ARGF.close

As of Ruby 2.3, IO#close no longer raises IOError if the file is already
closed.
------------------------------------------------------------------------
r57148 | hsbt | 2016-12-22 12:53:53 +0900 (Thu, 22 Dec 2016) | 1 line

Update xmlrpc-0.2.1 for Ruby 2.4.0 release.
------------------------------------------------------------------------
r57147 | nobu | 2016-12-22 11:00:02 +0900 (Thu, 22 Dec 2016) | 4 lines

test_rinda.rb: ipv6_mc

* test/rinda/test_rinda.rb (RingIPv6#ipv6_mc): extract IPv6
  multicast setup and cleanup, and ignore ENETDOWN.
------------------------------------------------------------------------
r57146 | rhe | 2016-12-22 10:43:41 +0900 (Thu, 22 Dec 2016) | 14 lines

openssl: import v2.0.2

Import Ruby/OpenSSL 2.0.2. This release contains only bugfixes. The full
commit log since 2.0.1 (imported at r57041) can be found at:

  https://github.com/ruby/openssl/compare/v2.0.1...v2.0.2

----------------------------------------------------------------
Kazuki Yamaguchi (5):
      ssl: check for SSL_CTX_clear_options()
      Rename functions in openssl_missing.c
      ssl: use SSL_SESSION_get_protocol_version()
      pkey: allow instantiating OpenSSL::PKey::PKey with unsupported key type
      Ruby/OpenSSL 2.0.2
------------------------------------------------------------------------
r57145 | mrkn | 2016-12-22 00:35:29 +0900 (Thu, 22 Dec 2016) | 5 lines

bigdecimal: version 1.3.0

Import bigdecimal version 1.3.0.  The full commit log is here:

  https://github.com/ruby/bigdecimal/compare/v1.3.0.pre.2...v1.3.0
------------------------------------------------------------------------
r57144 | svn | 2016-12-22 00:21:20 +0900 (Thu, 22 Dec 2016) | 1 line

* 2016-12-22
------------------------------------------------------------------------
r57143 | ngoto | 2016-12-22 00:21:19 +0900 (Thu, 22 Dec 2016) | 5 lines

regcomp.c: Fix compile error with old version of fcc on Solaris

* regcomp.c (get_min_match_length): Fix compile error with old version
  of fcc (Fujitsu C Compiler) on Solaris 10. [Bug #13059][ruby-dev:49909]

------------------------------------------------------------------------
r57142 | nobu | 2016-12-21 22:46:46 +0900 (Wed, 21 Dec 2016) | 1 line

time.c: debug print
------------------------------------------------------------------------
r57141 | yui-knk | 2016-12-21 22:26:16 +0900 (Wed, 21 Dec 2016) | 4 lines

numeric.c: remove not used lines

* numeric.c (rb_num_get_rounding_option): remove not used
  lines. After r57130 these lines are never reached.
------------------------------------------------------------------------
r57140 | nobu | 2016-12-21 21:06:40 +0900 (Wed, 21 Dec 2016) | 4 lines

time.c: refine num_exact error message

* time.c (num_exact): show the original argument when conversion
  failed, instead of intermediate nil.
------------------------------------------------------------------------
r57139 | nobu | 2016-12-21 21:05:41 +0900 (Wed, 21 Dec 2016) | 4 lines

time.c: use RB_TYPE_P

* time.c (time_timespec): use RB_TYPE_P instead of switching by
  TYPE.
------------------------------------------------------------------------
r57138 | nobu | 2016-12-21 20:20:02 +0900 (Wed, 21 Dec 2016) | 4 lines

st.c: suppress a warning

* st.c (st_hash): suppress unused label warning on 32bit
  platforms.  fix up r57134.
------------------------------------------------------------------------
r57137 | nobu | 2016-12-21 20:12:39 +0900 (Wed, 21 Dec 2016) | 4 lines

eval.c: fix circular cause

* eval.c (exc_setup_cause): always set cause of cause to get rid
  of circular references.  [ruby-core:78688] [Bug #13043]
------------------------------------------------------------------------
r57136 | usa | 2016-12-21 17:13:42 +0900 (Wed, 21 Dec 2016) | 2 lines

* win32/win32.c (winnt_stat): use `numberof` macro instead of constant.

------------------------------------------------------------------------
r57135 | usa | 2016-12-21 16:50:14 +0900 (Wed, 21 Dec 2016) | 8 lines

Fixed potentially buffer overrun.

* win32/win32.c (winnt_stat): the return value of `get_final_path` is the
  expected buffer length, not the actuall filled length.

* win32/win32.c (winnt_stat): `finalname` may be accessed in the outer block of
  its definition via `path`.

------------------------------------------------------------------------
r57134 | nobu | 2016-12-21 15:22:16 +0900 (Wed, 21 Dec 2016) | 29 lines

st.c: fix st_hash* functions [Bug #13019]

Previous implementation had an issues:
- macros murmur1 assumes murmur_step takes rotation value
  as a second argument
- but murmur_step second argument is "next block"
- this makes st_hash_uint and st_hash_end to not mix high bits of
  hash value into lower bits
- this leads to pure hash behavior on doubles and mixing hashes using
  st_hash_uint.
  It didn't matter when bins amount were prime numbers, but it hurts
  when bins are powers of two.

Mistake were created cause of attempt to co-exist Murmur1 and Murmur2
in a same code.

Change it to single hash-function implementation.
- block function is in a spirit of Murmur functions,
  but handles inter-block dependency a bit better (imho).
- final block is read in bit more optimal way on CPU with unaligned word access,
- final block is mixed in simple way,
- finalizer is taken from MurmurHash3 (it makes most of magic :) )
  (64bit finalizer is taken from
  http://zimbry.blogspot.ru/2011/09/better-bit-mixing-improving-on.html)

Also remove ST_USE_FNV1: it lacks implementation of many functions,
and looks to be abandoned

Author: Sokolov Yura aka funny_falcon <funny.falcon@gmail.com>
------------------------------------------------------------------------
r57133 | akr | 2016-12-21 14:26:35 +0900 (Wed, 21 Dec 2016) | 2 lines

[DOC] itemize values for half option of Float#round.

------------------------------------------------------------------------
r57132 | nobu | 2016-12-21 10:58:32 +0900 (Wed, 21 Dec 2016) | 4 lines

compile.c: toplevel return

* compile.c (iseq_compile_each): stop execution of the current source
  by toplevel return.  [ruby-core:36785] [Feature #4840]
------------------------------------------------------------------------
r57131 | nobu | 2016-12-21 10:29:58 +0900 (Wed, 21 Dec 2016) | 3 lines

numeric.c: rdoc of half option [ci skip]

* numeric.c (flo_round): [DOC] mention half option.  [Bug #12548]
------------------------------------------------------------------------
r57130 | nobu | 2016-12-21 10:29:57 +0900 (Wed, 21 Dec 2016) | 4 lines

numeric.c: allow nil as rounding mode option

* numeric.c (rb_num_get_rounding_option): allow nil same as the
  default behavior, per [ruby-core:77961].  [Bug #12548]
------------------------------------------------------------------------
r57129 | nobu | 2016-12-21 02:15:37 +0900 (Wed, 21 Dec 2016) | 4 lines

rdoc for r57126 [ci skip]

* ext/zlib/zlib.c: [DOC] update as keyword arguments.
  [Feature #13020]
------------------------------------------------------------------------
r57128 | svn | 2016-12-21 01:02:22 +0900 (Wed, 21 Dec 2016) | 1 line

* 2016-12-21
------------------------------------------------------------------------
r57127 | naruse | 2016-12-21 01:02:22 +0900 (Wed, 21 Dec 2016) | 1 line

suppress warning: attempt to close unfinished zstream; reset forced.
------------------------------------------------------------------------
r57126 | naruse | 2016-12-21 01:02:21 +0900 (Wed, 21 Dec 2016) | 1 line

Zlib.gzip uses kwargs instead of argc [Feature #13020]
------------------------------------------------------------------------
r57125 | nobu | 2016-12-20 17:25:03 +0900 (Tue, 20 Dec 2016) | 4 lines

io.c: update argf lineno

* io.c (argf_rewind): rewind line number in non-global ARGF
  instance.
------------------------------------------------------------------------
r57124 | nobu | 2016-12-20 17:25:02 +0900 (Tue, 20 Dec 2016) | 4 lines

io.c: update argf lineno

* io.c (argf_block_call_line): update line number in non-global
  ARGF instance.  [ruby-core:78728] [Bug #13051]
------------------------------------------------------------------------
r57123 | rhe | 2016-12-20 16:32:23 +0900 (Tue, 20 Dec 2016) | 5 lines

re.c: consider the case of RMatch::regexp is nil

Follow r49675, r57098 and r57110. Don't assume RMatch::regexp always
contains a valid Regexp instance; it will be Qnil if the MatchData is
created by rb_backref_set_string().  [ruby-core:78741] [Bug #13054]
------------------------------------------------------------------------
r57122 | rhe | 2016-12-20 15:53:45 +0900 (Tue, 20 Dec 2016) | 5 lines

string.c: add missing size_t cast

Add size_t cast to avoid signed integer overflow. r56157 ("string.c:
avoid signed integer overflow", 2016-09-13) missed this. Suppresses
UBSan.
------------------------------------------------------------------------
r57121 | rhe | 2016-12-20 15:53:44 +0900 (Tue, 20 Dec 2016) | 6 lines

array.c: do not resize to less than 0

Shrinking the Array from the block invoked by Array#select! or
Array#reject! causes the Array to be a negative number size. Ensure that
the resulting Array won't be smaller than 0.
[ruby-core:78739] [Bug #13053]
------------------------------------------------------------------------
r57120 | yuki | 2016-12-20 15:53:17 +0900 (Tue, 20 Dec 2016) | 2 lines

* gems/bundled_gems: Upgrade the did_you_mean gem to 1.1.0

------------------------------------------------------------------------
r57119 | rhe | 2016-12-20 14:26:08 +0900 (Tue, 20 Dec 2016) | 8 lines

array.c: check array length every time after yielding

Since the Array may be modified during rb_yield(), the length before
invoking the block can't be trusted. Fix possible out-of-bounds read in
Array#combination and Array#repeated_combination.

It may better to make a defensive copy of the Array, but for now let's
follow what Array#permutation does.  [ruby-core:78738] [Bug #13052]
------------------------------------------------------------------------
r57118 | rhe | 2016-12-20 14:26:07 +0900 (Tue, 20 Dec 2016) | 10 lines

proc.c: assume rb_iseq_location_t::first_lineno is always a Fixnum

Do not check for the value of rb_iseq_constant_body::line_info_table as
it is no longer related. The checks seem to be the remains from the day
before the dedicated 'first_lineno' field was introduced. Remove them.

Note, rb_iseq_constant_body::line_info_table can be NULL only when the
iseq does not contain any instructions that originate from Ruby code,
for example, an iseq created with 'proc {}' under a non-default compile
options where trace instructions are disabled.
------------------------------------------------------------------------
r57117 | svn | 2016-12-20 14:09:18 +0900 (Tue, 20 Dec 2016) | 1 line

* 2016-12-20
------------------------------------------------------------------------
r57116 | nobu | 2016-12-20 14:09:18 +0900 (Tue, 20 Dec 2016) | 4 lines

test/unit.rb: separator [ci skip]

* test/lib/test/unit.rb (ExcludesOption#setup_options): add
  separator for --excludes-dir in help message.
------------------------------------------------------------------------
r57115 | nobu | 2016-12-19 17:36:21 +0900 (Mon, 19 Dec 2016) | 4 lines

time.c: refine error message

* time.c (validate_vtm): separate validation failure messages for
  each members.
------------------------------------------------------------------------
r57114 | nobu | 2016-12-19 13:07:40 +0900 (Mon, 19 Dec 2016) | 4 lines

re.c: RB_TYPE_P

* re.c (match_backref_number, namev_to_backref_number): use
  RB_TYPE_P instead of switching by TYPE.
------------------------------------------------------------------------
r57113 | svn | 2016-12-19 12:11:58 +0900 (Mon, 19 Dec 2016) | 1 line

* 2016-12-19
------------------------------------------------------------------------
r57112 | nobu | 2016-12-19 12:11:57 +0900 (Mon, 19 Dec 2016) | 4 lines

re.c: NAME_TO_NUMBER

* re.c (namev_to_backref_number, rb_reg_regsub): extract name to
  backref number check as NAME_TO_NUMBER.
------------------------------------------------------------------------
r57111 | ktsj | 2016-12-18 21:29:34 +0900 (Sun, 18 Dec 2016) | 1 line

doc/standard_library.rdoc: Tk is removed from stdlib
------------------------------------------------------------------------
r57110 | nobu | 2016-12-18 20:43:51 +0900 (Sun, 18 Dec 2016) | 4 lines

re.c: use name_to_backref_number

* re.c (match_backref_number): use name_to_backref_number for
  casts.
------------------------------------------------------------------------
r57109 | naruse | 2016-12-18 20:28:01 +0900 (Sun, 18 Dec 2016) | 3 lines

Increase timeout

http://rubyci.s3.amazonaws.com/unstable10s/ruby-trunk/log/20161215T021909Z.fail.html.gz
------------------------------------------------------------------------
r57108 | nobu | 2016-12-18 03:04:30 +0900 (Sun, 18 Dec 2016) | 4 lines

sprintf.c: fix width underflow

* sprintf.c (rb_str_format): fix memory corruption by width
  underflow.  https://github.com/mruby/mruby/issues/3347
------------------------------------------------------------------------
r57107 | svn | 2016-12-18 01:10:57 +0900 (Sun, 18 Dec 2016) | 1 line

* 2016-12-18
------------------------------------------------------------------------
r57106 | naruse | 2016-12-18 01:10:56 +0900 (Sun, 18 Dec 2016) | 3 lines

Increase timeout

http://rubyci.org/logs/13.78.52.201/vc12-x64/ruby-trunk/log/20161217T103523Z.log.html.gz
------------------------------------------------------------------------
r57105 | rhe | 2016-12-17 17:25:34 +0900 (Sat, 17 Dec 2016) | 3 lines

compile.c: do not emit numeric literal range in void context

A fix-up for r56316. Fix stack consistency error on '1..3; nil'.
------------------------------------------------------------------------
r57104 | nobu | 2016-12-17 16:48:58 +0900 (Sat, 17 Dec 2016) | 1 line

Reapply r57093,r57094,r57097 "dtrace build fixes on FreeBSD"
------------------------------------------------------------------------
r57103 | nobu | 2016-12-17 16:48:57 +0900 (Sat, 17 Dec 2016) | 3 lines

Reapply r57092 "configure.in: repeated checks"

Needs DTRACE_OBJ when "$rb_cv_prog_dtrace_g" = rebuild, too.
------------------------------------------------------------------------
r57102 | nobu | 2016-12-17 14:27:05 +0900 (Sat, 17 Dec 2016) | 1 line

Revert r57092 "configure.in: repeated checks"
------------------------------------------------------------------------
r57101 | naruse | 2016-12-17 14:14:14 +0900 (Sat, 17 Dec 2016) | 1 line

Revert r57093,r57094,r57097 "dtrace build fixes on FreeBSD"
------------------------------------------------------------------------
r57100 | nobu | 2016-12-17 09:58:47 +0900 (Sat, 17 Dec 2016) | 4 lines

test_mailto.rb: overwritten methods

* test/uri/test_mailto.rb (URI::TestMailTo#test_to_mailtext):
  merge overwritten methods.  [Bug #10774]
------------------------------------------------------------------------
r57099 | nobu | 2016-12-17 09:58:46 +0900 (Sat, 17 Dec 2016) | 1 line

test_mailto.rb: adjust scope
------------------------------------------------------------------------
r57098 | nobu | 2016-12-17 09:52:47 +0900 (Sat, 17 Dec 2016) | 4 lines

re.c: non-regexp name reference

* re.c (rb_reg_regsub): other than regexp has no name references.
  [ruby-core:78686] [Bug #13042]
------------------------------------------------------------------------
r57097 | nobu | 2016-12-17 09:01:42 +0900 (Sat, 17 Dec 2016) | 4 lines

configure.in: fix r57093

* configure.in (RUBY_DTRACE_AVAILABLE): try -xnolibs first.
  [ruby-core:78676] [Bug #13041]
------------------------------------------------------------------------
r57096 | svn | 2016-12-17 07:57:02 +0900 (Sat, 17 Dec 2016) | 1 line

* 2016-12-17
------------------------------------------------------------------------
r57095 | nobu | 2016-12-17 07:57:01 +0900 (Sat, 17 Dec 2016) | 4 lines

fix r57089

* parse.y (parser_heredoc_identifier): fix multiline here document
  identifier condition.
------------------------------------------------------------------------
r57094 | nobu | 2016-12-16 21:28:19 +0900 (Fri, 16 Dec 2016) | 3 lines

garbage space [ci skip]

* configure.in (RUBY_DTRACE_AVAILABLE): remove a garbage space.
------------------------------------------------------------------------
r57093 | nobu | 2016-12-16 21:16:33 +0900 (Fri, 16 Dec 2016) | 5 lines

dtrace build fixes on FreeBSD

* configure.in (RUBY_DTRACE_AVAILABLE, RUBY_DTRACE_POSTPROCESS):
  incorporate dtrace build fix on FreeBSD, dtrace needs -xnolibs
  in a jail.  [ruby-core:78676] [Bug #13041]
------------------------------------------------------------------------
r57092 | nobu | 2016-12-16 20:59:57 +0900 (Fri, 16 Dec 2016) | 4 lines

configure.in: repeated checks

* configure.in (enable_dtrace): reduce repeated
  RUBY_DTRACE_AVAILABLE checks.
------------------------------------------------------------------------
r57091 | nobu | 2016-12-16 14:05:42 +0900 (Fri, 16 Dec 2016) | 4 lines

no crypt.h on FreeBSD 12

* string.c (crypt.h): crypt_r() was added in FreeBSD 12.0 but is
  declared in unistd.h.  [ruby-core:78664] [Bug #13038]
------------------------------------------------------------------------
r57090 | nobu | 2016-12-16 12:30:26 +0900 (Fri, 16 Dec 2016) | 4 lines

configure.in: no crypt.h on FreeBSD 12

* configure.in (crypt.h): crypt_r() was added in FreeBSD 12.0 but
  is declared in unistd.h.  [ruby-core:78664] [Bug #13038]
------------------------------------------------------------------------
r57089 | nobu | 2016-12-16 10:27:47 +0900 (Fri, 16 Dec 2016) | 4 lines

multiline heredoc identifier

* parse.y (parser_heredoc_identifier): reject multiline here
  document identifier, which never matches single line.
------------------------------------------------------------------------
r57088 | nobu | 2016-12-16 10:12:09 +0900 (Fri, 16 Dec 2016) | 6 lines

fix chomping newline only line

* string.c (chomp_newline): fix chomping newline only line.
  rb_enc_prev_char return NULL if no previous character and must
  not call rb_enc_ascget on it.  a patch by Ary Borenszweig
  <asterite AT gmail.com> at [ruby-core:78666].  [Bug #13037]
------------------------------------------------------------------------
r57087 | svn | 2016-12-16 01:08:34 +0900 (Fri, 16 Dec 2016) | 1 line

* 2016-12-16
------------------------------------------------------------------------
r57086 | mrkn | 2016-12-16 01:08:33 +0900 (Fri, 16 Dec 2016) | 1 line

NEWS: Fix the default rounding mode
------------------------------------------------------------------------
r57085 | nobu | 2016-12-15 21:58:59 +0900 (Thu, 15 Dec 2016) | 4 lines

parse.y: newline in heredoc identifier

* parse.y (parser_heredoc_identifier): warn newline in here
  document identifier.
------------------------------------------------------------------------
r57084 | hsbt | 2016-12-15 20:00:41 +0900 (Thu, 15 Dec 2016) | 1 line

Added entry of psych 2.2.2
------------------------------------------------------------------------
r57083 | hsbt | 2016-12-15 20:00:40 +0900 (Thu, 15 Dec 2016) | 3 lines

Update psych-2.2.2

 * It fixed only JRuby dependency issue.
------------------------------------------------------------------------
r57082 | nobu | 2016-12-15 15:22:09 +0900 (Thu, 15 Dec 2016) | 1 line

parse.y: one warning, one line [ci skip]
------------------------------------------------------------------------
r57081 | usa | 2016-12-15 02:53:20 +0900 (Thu, 15 Dec 2016) | 5 lines

Removed the obstacle to running test-all with VC14.

* test/fiddle/test_import.rb (LIBC.fprintf): VC14's `fprintf` is very distinct
  name, then, just ignore this test.

------------------------------------------------------------------------
r57080 | svn | 2016-12-15 02:49:27 +0900 (Thu, 15 Dec 2016) | 1 line

* 2016-12-15
------------------------------------------------------------------------
r57079 | usa | 2016-12-15 02:49:26 +0900 (Thu, 15 Dec 2016) | 6 lines

Fixed link error with VC14.

* win32/mkexports.rb (Exports::Mswin#each_exports): should ignore `vsprintf_s_l`
  and the like just like `vsprintf_l`.
  [ruby-dev:49899] [Bug #13033]

------------------------------------------------------------------------
r57078 | rhe | 2016-12-14 21:32:42 +0900 (Wed, 14 Dec 2016) | 9 lines

encoding.c: handle needmore error from rb_enc_precise_mbclen()

rb_enc_ascget() erroneously reports success even if the given byte
sequence is incomplete, for non-ASCII compatible encoding strings.

rb_enc_precise_mbclen() may return a negative value on error, and thus
rb_enc_ascget() must not store the return value in 'unsigned int';
otherwise the subsequent MBCLEN_CHARFOUND_P() check won't catch the
error.  [ruby-core:78646] [Bug #13034]
------------------------------------------------------------------------
r57077 | nobu | 2016-12-14 17:25:56 +0900 (Wed, 14 Dec 2016) | 5 lines

vcs.rb: no ext/date in vcs.rb

* tool/vcs.rb (VCS::GIT#export_changelog): do not require date
  extension library so that miniruby can run.
  [ruby-core:78641] [Bug #13032]
------------------------------------------------------------------------
r57076 | nobu | 2016-12-14 17:06:55 +0900 (Wed, 14 Dec 2016) | 4 lines

constify

* vm_dump.c (rb_vmdebug_debug_print_pre): constify pc argument for
  VMDEBUG.
------------------------------------------------------------------------
r57075 | nobu | 2016-12-14 16:30:41 +0900 (Wed, 14 Dec 2016) | 4 lines

parse.y: curtail scanning

* parse.y (parser_yyerror): curtail scanning range, not to exceed
  the max margin.
------------------------------------------------------------------------
r57074 | svn | 2016-12-14 13:35:29 +0900 (Wed, 14 Dec 2016) | 1 line

* 2016-12-14
------------------------------------------------------------------------
r57073 | nobu | 2016-12-14 13:35:28 +0900 (Wed, 14 Dec 2016) | 4 lines

parse.y: fix yyerror message

* parse.y (parser_yyerror): show the error line even if the error
  is at the end.
------------------------------------------------------------------------
r57072 | usa | 2016-12-13 14:17:48 +0900 (Tue, 13 Dec 2016) | 7 lines

declare `rb_w32_sysinit` in header.

* include/ruby/win32.h (rb_w32_sysinit): declare.
  [ruby-core:78444] [Bug #12994]

* ruby.c (ruby_sysinit): follow above change.

------------------------------------------------------------------------
r57071 | nobu | 2016-12-13 12:55:14 +0900 (Tue, 13 Dec 2016) | 1 line

require "irb/output-method" for StdioOutputMethod
------------------------------------------------------------------------
r57070 | nobu | 2016-12-13 12:55:13 +0900 (Tue, 13 Dec 2016) | 1 line

make-snapshot: fix circular dependency
------------------------------------------------------------------------
r57069 | hsbt | 2016-12-13 11:01:34 +0900 (Tue, 13 Dec 2016) | 1 line

Update description of XMLRPC section.
------------------------------------------------------------------------
r57068 | usa | 2016-12-13 01:18:45 +0900 (Tue, 13 Dec 2016) | 5 lines

get rid of a test failure with VC10.

* numeric.c (round_half_up, round_half_down): use `round` always because it's
  defined in this file even if doesn't exist.

------------------------------------------------------------------------
r57067 | svn | 2016-12-13 00:24:29 +0900 (Tue, 13 Dec 2016) | 1 line

* 2016-12-13
------------------------------------------------------------------------
r57066 | naruse | 2016-12-13 00:24:28 +0900 (Tue, 13 Dec 2016) | 4 lines

Use URI.decode_www_form_component [Bug #10774]

`parser` refered RFC2396_Parser, but it is separated.
test is contributed by Dominik Menke
------------------------------------------------------------------------
r57065 | naruse | 2016-12-12 23:55:15 +0900 (Mon, 12 Dec 2016) | 4 lines

st: Add 'static const'

patched by Ken Takata [ruby-core:78558]
https://github.com/k-takata/Onigmo/commit/44e3c0a16da1116be641ea807c1202434b743ace
------------------------------------------------------------------------
r57062 | naruse | 2016-12-12 22:37:27 +0900 (Mon, 12 Dec 2016) | 1 line

fix command
------------------------------------------------------------------------
r57060 | naruse | 2016-12-12 22:20:00 +0900 (Mon, 12 Dec 2016) | 3 lines

Use 7z if exist

7z can compress with higher ratio than gzip/zip.
------------------------------------------------------------------------
r57059 | kazu | 2016-12-12 22:12:08 +0900 (Mon, 12 Dec 2016) | 1 line

NEWS: Add String#match? and Symbol#match? [ci skip]
------------------------------------------------------------------------
r57058 | kazu | 2016-12-12 22:12:06 +0900 (Mon, 12 Dec 2016) | 1 line

NEWS: Use spaces instead of tab [ci skip]
------------------------------------------------------------------------
r57057 | kazu | 2016-12-12 22:12:05 +0900 (Mon, 12 Dec 2016) | 1 line

NEWS: Sort entries [ci skip]
------------------------------------------------------------------------
r57056 | nobu | 2016-12-12 16:12:07 +0900 (Mon, 12 Dec 2016) | 4 lines

string.c: fix method name in rdoc [ci skip]

* string.c (rb_str_equal): [DOC] fix fallback method name. the
  peer's == method will be used, not ===.
------------------------------------------------------------------------
r57055 | nobu | 2016-12-12 12:19:52 +0900 (Mon, 12 Dec 2016) | 1 line

test for Symbol#match?  [Feature #12898]
------------------------------------------------------------------------
r57054 | nobu | 2016-12-12 12:07:47 +0900 (Mon, 12 Dec 2016) | 4 lines

test_m17n.rb: escape

* test/ruby/test_m17n.rb (test_regexp_ascii_none): escape regexp
  meta characters.
------------------------------------------------------------------------
r57053 | nobu | 2016-12-12 11:56:12 +0900 (Mon, 12 Dec 2016) | 5 lines

String#match? and Symbol#match?

* string.c (rb_str_match_m_p): inverse of Regexp#match?.  based on
  the patch by Herwin Weststrate <herwin@snt.utwente.nl>.
  [Fix GH-1483] [Feature #12898]
------------------------------------------------------------------------
r57052 | svn | 2016-12-12 11:38:54 +0900 (Mon, 12 Dec 2016) | 1 line

* 2016-12-12
------------------------------------------------------------------------
r57051 | nobu | 2016-12-12 11:38:53 +0900 (Mon, 12 Dec 2016) | 4 lines

re.c: char boundary

* re.c (rb_reg_match_m_p): consider char boundary.  rb_str_subpos
  does not adjust to the boundary if len == 0.
------------------------------------------------------------------------
r57050 | nobu | 2016-12-11 18:20:27 +0900 (Sun, 11 Dec 2016) | 4 lines

parse.y: zero codepoints

* parse.y (parser_tokadd_utf8): relax restriction to allow zero or
  more codepoints.
------------------------------------------------------------------------
r57049 | naruse | 2016-12-11 15:13:02 +0900 (Sun, 11 Dec 2016) | 1 line

fix Zlib.gzip/gunzip document
------------------------------------------------------------------------
r57048 | naruse | 2016-12-11 03:34:07 +0900 (Sun, 11 Dec 2016) | 7 lines

Updated documentation examples for Hash#value?

The same code is used for has_value? and value?, but according to
http://blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-core/43765
has_value is deprecated. Use the non-deprecated syntax in the examples.
by Herwin Weststrate <herwin@snt.utwente.nl>
fix https://github.com/ruby/ruby/pull/1491
------------------------------------------------------------------------
r57047 | naruse | 2016-12-11 03:23:33 +0900 (Sun, 11 Dec 2016) | 7 lines

Add missing :nodoc: comment

We were missing a `:nodoc:` magic comment that was making automated tools show
that this method was missing documentation, when it really didn't need to be
documented.
by Devon Estes <devon.c.estes@gmail.com>
https://github.com/ruby/ruby/pull/1482 fix GH-1482
------------------------------------------------------------------------
r57046 | svn | 2016-12-11 02:47:06 +0900 (Sun, 11 Dec 2016) | 1 line

* 2016-12-11
------------------------------------------------------------------------
r57045 | naruse | 2016-12-11 02:47:04 +0900 (Sun, 11 Dec 2016) | 8 lines

Merge Onigmo 6.0.0

* https://github.com/k-takata/Onigmo/blob/Onigmo-6.0.0/HISTORY
* fix for ruby 2.4: https://github.com/k-takata/Onigmo/pull/78
* suppress warning: https://github.com/k-takata/Onigmo/pull/79
* include/ruby/oniguruma.h: include onigmo.h.
* template/encdb.h.tmpl: ignore duplicated definition of EUC-CN in
  enc/euc_kr.c. It is defined in enc/gb2313.c with CRuby macro.
------------------------------------------------------------------------
r57044 | mrkn | 2016-12-10 17:56:05 +0900 (Sat, 10 Dec 2016) | 5 lines

bigdecimal: version 1.3.0.pre.2

Import bigdecimal version 1.3.0.pre.2.  The full commit log is here:

  https://github.com/ruby/bigdecimal/compare/v1.3.0.pre...v1.3.0.pre.2
------------------------------------------------------------------------
r57043 | nobu | 2016-12-10 17:54:40 +0900 (Sat, 10 Dec 2016) | 4 lines

stringio.c: chomp CR

* ext/stringio/stringio.c (strio_getline): chomp CR not only LF,
  as well as String#chomp.
------------------------------------------------------------------------
r57042 | nobu | 2016-12-10 17:26:40 +0900 (Sat, 10 Dec 2016) | 5 lines

zlib.c: replace with substring

* ext/zlib/zlib.c (zstream_discard_input): replace with unread
  portion substring, not modifying the input buffer directly.
  [ruby-core:78567] [Bug #13021]
------------------------------------------------------------------------
r57041 | rhe | 2016-12-10 17:12:02 +0900 (Sat, 10 Dec 2016) | 9 lines

openssl: import v2.0.1

Import Ruby/OpenSSL 2.0.1. The full commit history since 2.0.0 (imported
at r56946) can be found at:

  https://github.com/ruby/openssl/compare/v2.0.0...v2.0.1

This release contains only bug fixes. Note, the first two commits since
v2.0.0 are already imported at r56953 to make Travis and RubyCI green.
------------------------------------------------------------------------
r57040 | mrkn | 2016-12-10 16:49:15 +0900 (Sat, 10 Dec 2016) | 6 lines

bigdecimal: import version 1.3.0.pre

Import bigdecimal version 1.3.0.pre.  The full commit log of this
changes can be found at:

    https://github.com/ruby/bigdecimal/compare/5c43a9e...v1.3.0.pre
------------------------------------------------------------------------
r57039 | nobu | 2016-12-10 15:25:26 +0900 (Sat, 10 Dec 2016) | 1 line

Fix grammer [ci skip]
------------------------------------------------------------------------
r57038 | mrkn | 2016-12-10 11:36:16 +0900 (Sat, 10 Dec 2016) | 10 lines

internal.h: change the default rounding mode to half-up

* internal.h (ROUND_DEFAULT): changed to RUBY_NUM_ROUND_HALF_UP.
  [Bug #12958] [ruby-core:78204]

* test/ruby/test_integer.rb: fix assertions for the above change.

* test/ruby/test_rational.rb: ditto.

* test/test_mathn.rb: ditto.
------------------------------------------------------------------------
r57037 | kazu | 2016-12-10 11:16:55 +0900 (Sat, 10 Dec 2016) | 5 lines

Fix document of gunzip and gzip [ci skip]

- fix a typo (`GzipReadr` -> `GzipReader`)
- `Zlib::GzipReader.new` does not take block
- fix encoding
------------------------------------------------------------------------
r57036 | svn | 2016-12-10 07:45:39 +0900 (Sat, 10 Dec 2016) | 1 line

* 2016-12-10
------------------------------------------------------------------------
r57035 | naruse | 2016-12-10 07:45:39 +0900 (Sat, 10 Dec 2016) | 3 lines

Zlib.gzip and Zlib.gunzip [Feature #13020]

Encode and Decode gzip data without creating files.
------------------------------------------------------------------------
r57034 | naruse | 2016-12-10 07:45:38 +0900 (Sat, 10 Dec 2016) | 4 lines

Suppress warning: this use of "defined" may not be portable

Use of defined() in macro expansion is considered non portable.
https://gcc.gnu.org/ml/gcc-patches/2014-10/msg01577.html
------------------------------------------------------------------------
r57033 | nobu | 2016-12-09 12:25:20 +0900 (Fri, 09 Dec 2016) | 4 lines

ruby.h: add prefix

* include/ruby/ruby.h (RB_TEST, RB_NIL_P): prefix RB to get rid of
  name conflicts with other headers.
------------------------------------------------------------------------
r57032 | nobu | 2016-12-09 11:59:55 +0900 (Fri, 09 Dec 2016) | 1 line

Adjust indent [ci skip]
------------------------------------------------------------------------
r57031 | svn | 2016-12-09 11:57:58 +0900 (Fri, 09 Dec 2016) | 1 line

* 2016-12-09
------------------------------------------------------------------------
r57030 | nobu | 2016-12-09 11:57:57 +0900 (Fri, 09 Dec 2016) | 6 lines

remove core#hash_merge_ary

* compile.c (compile_array_): remove m_core_hash_merge_ary which
  seems unreachable, and wrong number of arguments.

* vm.c (m_core_hash_merge_ary): removed because it is never used.
------------------------------------------------------------------------
r57029 | nobu | 2016-12-08 22:51:34 +0900 (Thu, 08 Dec 2016) | 4 lines

compile.c: static_literal_value

* compile.c (static_literal_value): separate getter from predicate
  function.
------------------------------------------------------------------------
r57028 | kazu | 2016-12-08 21:58:26 +0900 (Thu, 08 Dec 2016) | 10 lines

extension.rdoc: add ANYARGS to method definitions

* doc/extension.rdoc (rb_define_method, rb_define_singleton_method,
  rb_define_private_method, rb_define_protected_method,
  rb_define_module_function, rb_define_global_function): set ANYARGS
  as arguments to their underlying functions.

[ci skip]
Patch by: Dmitry Gritsay <unseductable@gmail.com>
[Fix GH-1473]
------------------------------------------------------------------------
r57027 | nobu | 2016-12-08 17:31:01 +0900 (Thu, 08 Dec 2016) | 5 lines

ruby-lex.rb: fix for label

* lib/irb/ruby-lex.rb (identify_identifier): treat identifier just
  followed by a colon as a lable.  this is not a precise solution
  but enough for the time being.  [ruby-core:78526] [Bug #13012]
------------------------------------------------------------------------
r57026 | nobu | 2016-12-08 17:25:21 +0900 (Thu, 08 Dec 2016) | 4 lines

test/unit.rb: fix -n option

* test/lib/test/unit.rb (non_options): turn name patterns into
  Regexps.
------------------------------------------------------------------------
r57025 | nobu | 2016-12-08 16:54:58 +0900 (Thu, 08 Dec 2016) | 5 lines

compile.c: optimize literal nodes

* compile.c (static_literal_node_p): optimize literal nodes for
  true, false, and nil, which are static literals in specific
  nodes but not in NODE_LIT.
------------------------------------------------------------------------
r57024 | nobu | 2016-12-08 15:19:06 +0900 (Thu, 08 Dec 2016) | 4 lines

vm.c: check type of hash to merge

* vm.c (core_hash_merge): check the type of the target hash to
  merge.  [ruby-core:78536] [Bug #13015]
------------------------------------------------------------------------
r57023 | nobu | 2016-12-08 14:16:33 +0900 (Thu, 08 Dec 2016) | 4 lines

vm_insnhelper.c: zsuper in refinements

* vm_insnhelper.c (vm_call_zsuper): prevent infinite recursion
  zsuper in refinements.  [ruby-core:77161] [Bug #12729]
------------------------------------------------------------------------
r57022 | nobu | 2016-12-08 09:45:13 +0900 (Thu, 08 Dec 2016) | 4 lines

parse.y: ripper generic input

* parse.y (ripper_initialize): allow generic input as source, if
  it has #gets method.
------------------------------------------------------------------------
r57021 | shugo | 2016-12-08 08:47:59 +0900 (Thu, 08 Dec 2016) | 12 lines

Add volatile to a suppress warning.

Without the fix, the following warning is shown:

    compiling cont.c
    cont.c: In function ?\226?\128?\152rb_callcc?\226?\128?\153:
    cont.c:949:39: warning: passing argument 1 of ?\226?\128?\152cont_capture?\226?\128?\153 discards ?\226?\128?\152volatile?\226?\128?\153 qualifier from pointer target type [-Wdiscarded-qualifiers]
	 volatile VALUE val = cont_capture(&called);
					   ^
    cont.c:473:1: note: expected ?\226?\128?\152int * volatile?\226?\128?\153 but argument is of type ?\226?\128?\152volatile int *?\226?\128?\153
     cont_capture(int *volatile stat)
     ^
------------------------------------------------------------------------
r57020 | shugo | 2016-12-08 08:27:51 +0900 (Thu, 08 Dec 2016) | 5 lines

Add clang volatile fixes from FreeBSD and NetBSD.

Use volatile instead of optnone to avoid optimization which causes
segmentation faults.
Patch by Dimitry Andric.  [ruby-core:78531] [Bug #13014]
------------------------------------------------------------------------
r57019 | svn | 2016-12-08 00:30:02 +0900 (Thu, 08 Dec 2016) | 1 line

* 2016-12-08
------------------------------------------------------------------------
r57018 | kazu | 2016-12-08 00:30:01 +0900 (Thu, 08 Dec 2016) | 9 lines

fix typo in `IO#write_nonblock` example [ci skip]

This example explains when writing a value greater than 65536,
so the value specify must be greater than 65536.

This seems to be wrong in cee7f69

Patch by: Yuji Yaginuma <yuuji.yaginuma@gmail.com>
[Fix GH-1496]
------------------------------------------------------------------------
r57017 | nobu | 2016-12-07 23:39:24 +0900 (Wed, 07 Dec 2016) | 4 lines

ruby.c: dump option

* ruby.c (process_options): dump specified informations all, not
  only first one.
------------------------------------------------------------------------
r57016 | nobu | 2016-12-07 23:26:44 +0900 (Wed, 07 Dec 2016) | 4 lines

assertions.rb: defered message in FailDesc

* test/lib/test/unit/assertions.rb (FailDesc): allow to defer
  message generation, as well as other assertion methods.
------------------------------------------------------------------------
r57015 | svn | 2016-12-07 21:59:49 +0900 (Wed, 07 Dec 2016) | 1 line

* properties.
------------------------------------------------------------------------
r57014 | shugo | 2016-12-07 21:59:48 +0900 (Wed, 07 Dec 2016) | 5 lines

Delay Utils.getservername until needed.

There is no need to call Utils.getservername when the :ServerName option is
specified, so delay Utils.getservername until needed to avoid unnecessary
DNS lookups.  [ruby-core:78492] [Bug #13007]
------------------------------------------------------------------------
r57013 | nobu | 2016-12-07 17:44:34 +0900 (Wed, 07 Dec 2016) | 6 lines

compile.c: remove dead code

* compile.c (DECL_ANCHOR, INIT_ANCHOR): make anchor name an array
  and unassignable.

* compile.c (iseq_compile_each): ret is never 0.
------------------------------------------------------------------------
r57012 | nobu | 2016-12-07 13:25:50 +0900 (Wed, 07 Dec 2016) | 4 lines

hash.c: hash should be long

* hash.c (any_hash): should return `long', because ruby assumes
  the hash value of the object id of an object is `long'.
------------------------------------------------------------------------
r57011 | nobu | 2016-12-07 12:19:33 +0900 (Wed, 07 Dec 2016) | 4 lines

win32.c: suppress warning

* win32/win32.c (rb_w32_home_dir): suppress sequence-point
  warning, REALLOC_N re-assigns the variable.
------------------------------------------------------------------------
r57010 | shugo | 2016-12-07 11:41:00 +0900 (Wed, 07 Dec 2016) | 3 lines

Extend timeout for Solaris unstable10s.

http://rubyci.org/logs/rubyci.s3.amazonaws.com/unstable10s/ruby-trunk/log/20161206T181910Z.fail.html.gz
------------------------------------------------------------------------
r57009 | nobu | 2016-12-07 11:19:29 +0900 (Wed, 07 Dec 2016) | 4 lines

file.c: cygwin behavior

* file.c: recent cygwin hides NTFS specific features.
  [ruby-core:78497] [Bug #13008]
------------------------------------------------------------------------
r57008 | svn | 2016-12-07 11:03:41 +0900 (Wed, 07 Dec 2016) | 1 line

* 2016-12-07
------------------------------------------------------------------------
r57007 | usa | 2016-12-07 11:03:40 +0900 (Wed, 07 Dec 2016) | 4 lines

const pointer is not able to be free.

* win32/file.c (rb_default_home_dir): should not be marked as const.

------------------------------------------------------------------------
r57006 | kazu | 2016-12-07 00:33:49 +0900 (Wed, 07 Dec 2016) | 4 lines

untabify [ci skip]

based on the patch by W <wolf@wolfsden.cz>
[Fix GH-1497]
------------------------------------------------------------------------
r57005 | kazu | 2016-12-07 00:33:47 +0900 (Wed, 07 Dec 2016) | 1 line

Fix indent [ci skip]
------------------------------------------------------------------------
r57004 | svn | 2016-12-06 22:57:57 +0900 (Tue, 06 Dec 2016) | 1 line

* properties.
------------------------------------------------------------------------
r57003 | kou | 2016-12-06 22:57:56 +0900 (Tue, 06 Dec 2016) | 2 lines

rexml: REXML::Element#[] accepts String or Symbol as attribute name

------------------------------------------------------------------------
r57002 | nobu | 2016-12-06 22:57:23 +0900 (Tue, 06 Dec 2016) | 6 lines

Make `trace_running` an integer flag again

* vm_core.h (rb_vm_struct): trace_running should be a counter but
  not a bit flag.  [ruby-core:78514] [Bug #13011]

Author: David Rodr?\195?\173guez <deivid.rodriguez@gmail.com>
------------------------------------------------------------------------
r57001 | mrkn | 2016-12-06 22:40:31 +0900 (Tue, 06 Dec 2016) | 9 lines

array.c, enum.c: change sum algorithm

* array.c (rb_ary_sum): change the algorithm to Kahan-Babuska balancing
  summation to be more precise.
  [Feature #12871] [ruby-core:77771]

* enum.c (sum_iter, enum_sum): ditto.

* test_array.rb, test_enum.rb: add an assertion for the above change.
------------------------------------------------------------------------
r57000 | mrkn | 2016-12-06 21:54:19 +0900 (Tue, 06 Dec 2016) | 6 lines

numeric.c: fix exception message for nil rounding

* numeric.c (rb_num_get_rounding_option): fix exception message
  for the case of nil rounding mode.

* test_float.rb: add an assertion for the above change.
------------------------------------------------------------------------
r56999 | kazu | 2016-12-06 21:49:46 +0900 (Tue, 06 Dec 2016) | 4 lines

Fix typos

Patch by: Koichi ITO <koic.ito@gmail.com>
[Fix GH-1498]
------------------------------------------------------------------------
r56998 | hsbt | 2016-12-06 20:57:19 +0900 (Tue, 06 Dec 2016) | 4 lines

Update latest bundled gems.

  * Rake 12.0.0
  * minitest 5.10.1
------------------------------------------------------------------------
r56997 | nobu | 2016-12-06 16:46:14 +0900 (Tue, 06 Dec 2016) | 4 lines

EPERM by symlink

* test/ruby/test_file.rb (test_realpath_encoding): EPERM can raise
  on cygwin.
------------------------------------------------------------------------
r56996 | nobu | 2016-12-06 16:21:55 +0900 (Tue, 06 Dec 2016) | 4 lines

file.c: isADS

* file.c (isADS): add macro to tell if Alternate Data Stream
  separator, to distinguish from drive letter.
------------------------------------------------------------------------
r56995 | nobu | 2016-12-06 15:16:57 +0900 (Tue, 06 Dec 2016) | 4 lines

EPERM by symlink

* test/ruby/test_file_exhaustive.rb (symlinkfile): EPERM can raise
  on cygwin.
------------------------------------------------------------------------
r56994 | rhe | 2016-12-06 15:14:17 +0900 (Tue, 06 Dec 2016) | 5 lines

re.c: check that MatchData is initialized

Follow r16757 ("* re.c: fix SEGV by Regexp.allocate.names,
Match.allocate.names, etc.", 2008-06-02). Don't do null dereference if
MatchData#hash or #== is called against an uninitialized instance.
------------------------------------------------------------------------
r56993 | rhe | 2016-12-06 15:14:16 +0900 (Tue, 06 Dec 2016) | 4 lines

test/ruby/test_hash.rb: suppress syntax warning

Avoid "ambiguous first argument; put parentheses or a space even after
`-' operator" warning in assert_in_out_err. Fixes r56992.
------------------------------------------------------------------------
r56992 | nobu | 2016-12-06 13:43:48 +0900 (Tue, 06 Dec 2016) | 23 lines

switching hash removal

* st.h (struct st_hash_type): Remove strong_hash.
  (struct st_table): Remove inside_rebuild_p and curr_hash.
* st.c (do_hash): Use type->hash instead of curr_hash.
  (make_tab_empty): Remove setting up curr_hash.
  (st_init_table_with_size): Remove setting up inside_rebuild_p.
  (rebuild_table): Remove clearing inside_rebuild_p.
  (reset_entry_hashes, HIT_THRESHOULD_FOR_STRONG_HASH): Remove code
  recognizing a denial attack and switching to strong hash.
* hash.c (rb_dbl_long_hash, rb_objid_hash, rb_ident_hash): Use
  rb_hash_start to randomize the hash.
  (str_seed): Remove.
  (any_hash): Remove strong_p and use always rb_str_hash for
  strings.
  (any_hash_weak, rb_any_hash_weak): Remove.
  (st_hash_type objhash): Remove rb_any_hash_weak.

based on the patch by Vladimir N Makarov <vmakarov@redhat.com> at
[ruby-core:78490].  [Bug #13002]

* test/ruby/test_hash.rb (test_wrapper): objects other than special
  constants should be able to be wrapped.
------------------------------------------------------------------------
r56991 | nobu | 2016-12-06 12:36:52 +0900 (Tue, 06 Dec 2016) | 5 lines

remove unnecessary variable

* st.c (do_hash): remove unnecessary variable and cast.

* hash.c, numeric.c, st.c: adjust style and indent.
------------------------------------------------------------------------
r56990 | nobu | 2016-12-06 12:25:21 +0900 (Tue, 06 Dec 2016) | 4 lines

random.c: pack hash seeds

* random.c (seed_keys_t, init_seed): pack seed for rb_hash_start and
  rb_memhash, and fill them at once.
------------------------------------------------------------------------
r56989 | svn | 2016-12-06 08:37:25 +0900 (Tue, 06 Dec 2016) | 1 line

* 2016-12-06
------------------------------------------------------------------------
r56988 | shugo | 2016-12-06 08:37:25 +0900 (Tue, 06 Dec 2016) | 1 line

Add a comment.
------------------------------------------------------------------------
r56987 | kazu | 2016-12-05 21:35:03 +0900 (Mon, 05 Dec 2016) | 1 line

Remove closed checks and use `&.`
------------------------------------------------------------------------
r56986 | kazu | 2016-12-05 21:35:02 +0900 (Mon, 05 Dec 2016) | 1 line

NEWS: mention chomp option of String and StringIO
------------------------------------------------------------------------
r56985 | shugo | 2016-12-05 20:10:05 +0900 (Mon, 05 Dec 2016) | 5 lines

Don't insert an entry to loading_tbl if another thread succeed to load.

If rb_thread_shield_wait() returns Qfalse, the file has been successfully
loaded by another thread, so there is no need to insert a new entry into
loading_tbl.  [ruby-core:78464] [Bug #12999]
------------------------------------------------------------------------
r56984 | nobu | 2016-12-05 09:03:45 +0900 (Mon, 05 Dec 2016) | 4 lines

random.c: private rand

* random.c (rb_random_ulong_limited): do not call private method
  rand.  [ruby-dev:49892] [Misc #13003]
------------------------------------------------------------------------
r56983 | svn | 2016-12-05 08:14:47 +0900 (Mon, 05 Dec 2016) | 1 line

* 2016-12-05
------------------------------------------------------------------------
r56982 | naruse | 2016-12-05 08:14:46 +0900 (Mon, 05 Dec 2016) | 4 lines

Increase timeout of TestRequire#test_require_with_loaded_features_pop

unstable10s fails it because of timeout
http://rubyci.s3.amazonaws.com/unstable10s/ruby-trunk/log/20161201T161908Z.fail.html.gz
------------------------------------------------------------------------
r56981 | nobu | 2016-12-04 17:50:29 +0900 (Sun, 04 Dec 2016) | 5 lines

class.c: missing unknown_keyword_error

* class.c (rb_get_kwargs): when values are stored, corresponding
  keys have been remove from the keyword hash, and the hash should
  be empty in that case.  [ruby-dev:49893] [Bug #13004]
------------------------------------------------------------------------
r56980 | nobu | 2016-12-04 17:50:28 +0900 (Sun, 04 Dec 2016) | 5 lines

extension.rdoc: fix rb_get_kwargs [ci skip]

* doc/extension.rdoc: [DOC] optional keyword arguments are
  defaulted to Qundef.  ignored keys are kept in the hash but a
  new Hash is not created.  [ruby-dev:49893] [Bug #13004]
------------------------------------------------------------------------
r56979 | ktsj | 2016-12-04 14:40:18 +0900 (Sun, 04 Dec 2016) | 4 lines

Revert changes on rb_frame_method_id_and_class()

r56593 introduced backwards incompatible changes in the API.
[ruby-core:78471] [Feature #12747]
------------------------------------------------------------------------
r56978 | shugo | 2016-12-04 14:05:54 +0900 (Sun, 04 Dec 2016) | 1 line

Specify the socktype explicitly.
------------------------------------------------------------------------
r56977 | shugo | 2016-12-04 13:53:33 +0900 (Sun, 04 Dec 2016) | 1 line

Use 127.0.0.1 if getaddrinfo fails.
------------------------------------------------------------------------
r56976 | duerst | 2016-12-04 10:58:54 +0900 (Sun, 04 Dec 2016) | 10 lines

remove special processing for U+03B9/U+03BC/U+A64B

* enc/unicode.c: Remove special processing for U+03B9/U+03BC/U+A64B
  (GREEK SMALL LETTERs IOTA/MU, CYRILLIC SMALL LETTER MONOGRAPH UK)
  from onigenc_unicode_case_map and simplify code.

* enc/unicode/case-folding.rb: Remove check for U+03B9/U+03BC/U+A64B.

This and the previous few related commits make sure that we won't hit
the equivalent of bug #12990 anymore for future updates of Unicode versions.
------------------------------------------------------------------------
r56975 | duerst | 2016-12-04 10:17:34 +0900 (Sun, 04 Dec 2016) | 6 lines

Reorder codepoints in some entries of CaseUnfold_11_Table

* enc/unicode/case-folding.rb: Reorder codepoints so that the upper-case
  mapping comes first.
* enc/unicode/9.0.0/casefold.h: Codepoints reordered, upper-case mapping
  flag added.
------------------------------------------------------------------------
r56974 | svn | 2016-12-04 00:41:15 +0900 (Sun, 04 Dec 2016) | 1 line

* 2016-12-04
------------------------------------------------------------------------
r56973 | shugo | 2016-12-04 00:41:14 +0900 (Sun, 04 Dec 2016) | 3 lines

Use IPv6 if it's preferred.

I hope this fix makes tests faster on Windows.
------------------------------------------------------------------------
r56972 | nobu | 2016-12-03 23:18:03 +0900 (Sat, 03 Dec 2016) | 3 lines

string.c: chomp option

* string.c (rb_str_enumerate_lines): implement chomp option.
------------------------------------------------------------------------
r56971 | kazu | 2016-12-03 20:18:44 +0900 (Sat, 03 Dec 2016) | 8 lines

Cleanup ruby method definitions in hash.c

Always add a space between a comma and the next element. These spaces
were there sometimes, but not always. This keeps to code consistent.

Patch by: Herwin Weststrate <herwin@snt.utwente.nl>

[ruby-core:78297] [Misc #12977] [GH-1492]
------------------------------------------------------------------------
r56970 | nobu | 2016-12-03 20:01:25 +0900 (Sat, 03 Dec 2016) | 3 lines

stringio: chomp option

* ext/stringio/stringio.c (strio_getline): implement chomp option.
------------------------------------------------------------------------
r56969 | nobu | 2016-12-03 20:01:24 +0900 (Sat, 03 Dec 2016) | 4 lines

test_stringio.rb: paragraph mode

* test/stringio/test_stringio.rb (test_gets, test_each):
  assertions for paragraph mode.
------------------------------------------------------------------------
r56968 | duerst | 2016-12-03 16:18:41 +0900 (Sat, 03 Dec 2016) | 5 lines

add tests againts regressions for upcoming codepoint reordering in unfolding table

* test/ruby/enc/test_case_mapping.rb: Add method test_reorder_unfold to test against
  problems when reordering codepoints in some entries in
  CaseUnfold_11_Type CaseUnfold_11_Table.
------------------------------------------------------------------------
r56967 | svn | 2016-12-03 14:09:10 +0900 (Sat, 03 Dec 2016) | 1 line

* 2016-12-03
------------------------------------------------------------------------
r56966 | duerst | 2016-12-03 14:09:09 +0900 (Sat, 03 Dec 2016) | 5 lines

change test class name because it is not only about folding

* test/ruby/enc/test_case_comprehensive.rb: Change test class name from
  TestComprehensiveCaseFold to TestComprehensiveCaseMapping because the
  tests are about mapping in general, not only folding
------------------------------------------------------------------------
r56965 | nobu | 2016-12-02 15:12:56 +0900 (Fri, 02 Dec 2016) | 1 line

test/ruby/test_string.rb: ensure restoring $/
------------------------------------------------------------------------
r56964 | nobu | 2016-12-02 12:33:54 +0900 (Fri, 02 Dec 2016) | 4 lines

parse.y: simplify parsing utf-8 string

* parse.y (parser_tokadd_codepoint): move error checks and add
  char.
------------------------------------------------------------------------
r56963 | nobu | 2016-12-02 11:47:11 +0900 (Fri, 02 Dec 2016) | 4 lines

parse.y: relax spaces

* parse.y (parser_tokadd_utf8): relax restriction spaces inside
  "\u{...}".
------------------------------------------------------------------------
r56962 | rhe | 2016-12-02 11:24:45 +0900 (Fri, 02 Dec 2016) | 5 lines

re.c: count associated Regexp object in MatchData#hash

Don't discard the hash value computed for the regexp object. It seems it
was simply missed out in r24754, when MatchData#hash was initially
implemented.
------------------------------------------------------------------------
r56961 | svn | 2016-12-02 02:43:42 +0900 (Fri, 02 Dec 2016) | 1 line

* 2016-12-02
------------------------------------------------------------------------
r56960 | naruse | 2016-12-02 02:43:41 +0900 (Fri, 02 Dec 2016) | 1 line

Remove unused variable
------------------------------------------------------------------------
r56959 | naruse | 2016-12-01 23:18:32 +0900 (Thu, 01 Dec 2016) | 3 lines

String#unpack1 [Feature #12752]

Returns the first value of String#unpack.
------------------------------------------------------------------------
r56958 | usa | 2016-12-01 22:20:47 +0900 (Thu, 01 Dec 2016) | 4 lines

Remove `offset:` from `Array#pack`

* pack.c (pack_pack): can use `@` instead of `offset:`.

------------------------------------------------------------------------
r56957 | usa | 2016-12-01 22:08:20 +0900 (Thu, 01 Dec 2016) | 5 lines

Supports `buffer` and `offset` in `Array#pack`

* pack.c (pack_pack): Supports `buffer` and `offset` in `Array#pack`.
  [Feature #12754] [ruby-dev:49798]

------------------------------------------------------------------------
r56956 | nobu | 2016-12-01 17:26:39 +0900 (Thu, 01 Dec 2016) | 4 lines

parse.y: reject invalid codepoint

* parse.y (parser_tokadd_codepoint): reject invalid codepoint,
  surrogate blocks and surrogate pair, as well as mruby.
------------------------------------------------------------------------
r56955 | hsbt | 2016-12-01 14:24:00 +0900 (Thu, 01 Dec 2016) | 4 lines

Update bundled_gems

  * minitest-5.10.0
  * test-unit-3.2.3
------------------------------------------------------------------------
r56954 | shugo | 2016-12-01 13:51:42 +0900 (Thu, 01 Dec 2016) | 10 lines

Wait until excpetion handling is ready.

Because RubyCI on Solaris 10 failed as follows:

    1) Failure:
  TestProcess#test_execopts_redirect_open_fifo_interrupt_raise [/export/home/rubyci/unstable10s/tmp/build/20161130T201909Z/ruby/test/ruby/test_process.rb:646]:
  <"ok\n"> expected but was
  <"">.

The argument of sleep (0.5) can be smaller, but I'm not sure.
------------------------------------------------------------------------
r56953 | rhe | 2016-12-01 13:42:10 +0900 (Thu, 01 Dec 2016) | 27 lines

openssl: import fixes from upstream

Import the following two commits from upstream:

  commit 72126d6c8b88abd69c3565fc3bbbd5ed1e401611
  Author: Kazuki Yamaguchi <k@rhe.jp>
  Date:   Thu Dec 1 22:27:03 2016 +0900

      pkey: check existence of EVP_PKEY_get0()

      EVP_PKEY_get0() did not exist in early OpenSSL 0.9.8 series. So define
      ourselves if needed.

  commit 94a1c4e0c5705ad1e9a4ca08cacaa6cba8b1e6f5
  Author: Kazuki Yamaguchi <k@rhe.jp>
  Date:   Thu Dec 1 22:13:22 2016 +0900

      test/test_cipher: fix test with OpenSSL 1.0.1 before 1.0.1d

      Set the authentication tag before the AAD when decrypting.

      Before OpenSSL commit 96f7fafa2431 ("Don't require tag before ciphertext
      in AESGCM mode", 2012-10-16, at OpenSSL_1_0_1-stable branch, included in
      OpenSSL 1.0.1d), the authentication tag must be set before any calls of
      EVP_CipherUpdate().

They should fix build on CentOS 5 and Ubuntu 12.04 respectively.
------------------------------------------------------------------------
r56952 | nobu | 2016-12-01 09:34:42 +0900 (Thu, 01 Dec 2016) | 1 line

Use offsetof macro and shrink table size
------------------------------------------------------------------------
r56951 | nobu | 2016-12-01 09:34:41 +0900 (Thu, 01 Dec 2016) | 1 line

constify CaseMappingSpecials
------------------------------------------------------------------------
r56950 | svn | 2016-12-01 02:29:20 +0900 (Thu, 01 Dec 2016) | 1 line

* 2016-12-01
------------------------------------------------------------------------
r56949 | naruse | 2016-12-01 02:29:19 +0900 (Thu, 01 Dec 2016) | 22 lines

Regexp supports Unicoe 9.0.0's \X

* meta character \X matches Unicode 9.0.0 characters with some workarounds
  for UTR #51 Unicode Emoji, Version 4.0 emoji zwj sequences.
  [Feature #12831] [ruby-core:77586]

The term "character" can have many meanings bytes, codepoints, combined
characters, and so on. "grapheme cluster" is highest one of such words,
which means user-perceived characters.
Unicode Standard Annex #29 UNICODE TEXT SEGMENTATION specifies how to
handle grapheme clusters (extended grapheme cluster).
But some specs aren't updated to current situation because Unicode Emoji
is rapidly extended without well definition.
It breaks the precondition of UTR#29 "Grapheme cluster boundaries can be
easily tested by looking at immediately adjacent characters". (the
sentence will be removed in the next version)
Though some of its detail are described in Unicode Technical Report #51
UNICODE EMOJI but it is not merged into UTR#29 yet.

http://unicode.org/reports/tr29/
http://unicode.org/reports/tr51/
http://unicode.org/Public/emoji/4.0/
------------------------------------------------------------------------
r56948 | nobu | 2016-11-30 23:54:09 +0900 (Wed, 30 Nov 2016) | 4 lines

ossl.c: cast

* ext/openssl/ossl.c (ossl_pem_passwd_cb): cast to int.  it's safe
  because len does not exceed int max_len.
------------------------------------------------------------------------
r56947 | nobu | 2016-11-30 23:43:43 +0900 (Wed, 30 Nov 2016) | 4 lines

parse.y: refine error message

* parse.y (parser_tokadd_utf8): refine error message at bad char
  in unicode escape, "invalid" instead of "unterminated".
------------------------------------------------------------------------
r56946 | rhe | 2016-11-30 23:41:46 +0900 (Wed, 30 Nov 2016) | 6 lines

openssl: import v2.0.0

Import Ruby/OpenSSL 2.0.0. The full commit history since 2.0.0 beta.2
(imported at r56098) can be found at:

  https://github.com/ruby/openssl/compare/v2.0.0.beta.2...v2.0.0
------------------------------------------------------------------------
r56945 | hsbt | 2016-11-30 23:24:12 +0900 (Wed, 30 Nov 2016) | 3 lines

Fixed error with `make install`

  rbinstall.rb couldn't load "psych/versions".
------------------------------------------------------------------------
r56944 | hsbt | 2016-11-30 22:55:02 +0900 (Wed, 30 Nov 2016) | 6 lines

Update psych-2.2.1

  It fixed segmentation fault related with GC.
  https://github.com/ruby/psych/pull/296

  and removed deprecated code of Ruby 1.8.
------------------------------------------------------------------------
r56943 | nobu | 2016-11-30 22:09:51 +0900 (Wed, 30 Nov 2016) | 4 lines

parse.y: parser_tokadd_codepoint

* parse.y (parser_tokadd_codepoint): extract from
  parser_tokadd_utf8.
------------------------------------------------------------------------
r56942 | nobu | 2016-11-30 22:09:50 +0900 (Wed, 30 Nov 2016) | 3 lines

parse.y: brace constants

* parse.y (parser_tokadd_utf8): make open/close braces constant.
------------------------------------------------------------------------
r56941 | duerst | 2016-11-30 17:25:46 +0900 (Wed, 30 Nov 2016) | 14 lines

fix uppercasing for U+A64B, CYRILLIC SMALL LETTER MONOGRAPH UK

* enc/unicode.c: Add U+A64B to the special cases 03B9 and 03BC
  at the end of onigenc_unicode_case_map (Bug #12990).

* enc/unicode/case-folding.rb: Add U+A64B to the special cases
  03B9 and 03BC. Add a comment pointing to enc/unicode.c.
  Change warnings to exceptions for unpredicted cases,
  because this would have been more easily noticed
  (the warning was not noticed when upgrading to Unicode 9.0.0).

* test/ruby/enc/test_case_comprehensive.rb: Remove temporary
  exclusion of U+A64B from testing.

------------------------------------------------------------------------
r56940 | nobu | 2016-11-30 10:40:11 +0900 (Wed, 30 Nov 2016) | 4 lines

parse.y: no warning for lambda

* parse.y (parser_yylex): do not warn parentheses of lambda
  argument list, because there is no name.
------------------------------------------------------------------------
r56939 | shugo | 2016-11-30 10:22:05 +0900 (Wed, 30 Nov 2016) | 1 line

Supress warnings.
------------------------------------------------------------------------
r56938 | tenderlove | 2016-11-30 02:06:35 +0900 (Wed, 30 Nov 2016) | 28 lines

Stop reading past the end of `ivptr` array

If you have code like this:

```ruby
class A
  def initialize
    @a = nil
    @b = nil
    @c = nil
    @d = nil
    @e = nil
  end
end

x = A.new
y = x.clone
100.times { |z| x.instance_variable_set(:"@foo#{z}", nil) }
puts y.inspect
```

`x` and `y` will share `iv_index_tbl` hashes.  However, the size of the
hash will grow larger than the number if entries in `ivptr` in `y`.
Before this commit, `rb_ivar_count` would use the size of the hash to
determine how far to read in to the array, but this means that it could
read past the end of the array and cause the program to segv

[ruby-core:78403]
------------------------------------------------------------------------
r56937 | nobu | 2016-11-30 01:06:54 +0900 (Wed, 30 Nov 2016) | 1 line

get rid of ambiguous parentheses warnings
------------------------------------------------------------------------
r56936 | rhe | 2016-11-30 00:48:47 +0900 (Wed, 30 Nov 2016) | 4 lines

webrick: don't use OpenSSL::TestUtils from webrick tests

Follow net/http and open-uri. Don't rely on the constants/methods from
OpenSSL::TestUtils.
------------------------------------------------------------------------
r56935 | rhe | 2016-11-30 00:48:46 +0900 (Wed, 30 Nov 2016) | 3 lines

open-uri: don't use OpenSSL::TestUtils from open-uri tests

Follow net/http. Define own test DH parameters and use.
------------------------------------------------------------------------
r56934 | rhe | 2016-11-30 00:48:45 +0900 (Wed, 30 Nov 2016) | 5 lines

net/http: don't use OpenSSL::TestUtils from test code

Make test code independent of test/openssl/utils.rb. The development of
openssl library has moved to a separate repository and
OpenSSL::TestUtils may be modified at any time.
------------------------------------------------------------------------
r56933 | nobu | 2016-11-30 00:34:31 +0900 (Wed, 30 Nov 2016) | 4 lines

object.c: no TypeError at special const

* object.c (special_object_p): no longer raise a TypeError for
  Integer and Float, and return itself instead.  [Feature#12979]
------------------------------------------------------------------------
r56932 | kazu | 2016-11-30 00:31:16 +0900 (Wed, 30 Nov 2016) | 3 lines

NEWS: Add String/Symbol#casecmp? [Feature #12786]

[ci skip]
------------------------------------------------------------------------
r56931 | usa | 2016-11-30 00:23:12 +0900 (Wed, 30 Nov 2016) | 4 lines

get rid of test failures on CI introduced at r56927

* lib/matrix.rb: now ruby warns ambiguous parentheses after a space in method definitions.

------------------------------------------------------------------------
r56930 | svn | 2016-11-30 00:14:06 +0900 (Wed, 30 Nov 2016) | 1 line

* 2016-11-30
------------------------------------------------------------------------
r56929 | nobu | 2016-11-30 00:14:05 +0900 (Wed, 30 Nov 2016) | 5 lines

object.c: no TypeError at special const clone

* object.c (rb_obj_clone2): no longer raise a TypeError for
  special constants, and return itself instead.  however, if
  freeze option is false, raise an ArgumentError.  [Feature#12979]
------------------------------------------------------------------------
r56928 | nobu | 2016-11-29 21:54:43 +0900 (Tue, 29 Nov 2016) | 8 lines

thread.c: fix doc of abort_on_exception [ci skip]

* thread.c (rb_thread_s_abort_exc, rb_thread_s_abort_exc_set):
  [DOC] the raised exception will be re-raised in the main thread,
  and then follows the ordinary exception sequence, exit status is
  not 0.  [ruby-core:78415] [Bug #12991]

* thread.c (rb_thread_abort_exc_set): ditto.
------------------------------------------------------------------------
r56927 | nobu | 2016-11-29 19:47:43 +0900 (Tue, 29 Nov 2016) | 4 lines

parse.y: ambiguous parentheses

* parse.y (parser_yylex): warn ambiguous parentheses after a space
  in method definitions.
------------------------------------------------------------------------
r56926 | duerst | 2016-11-29 19:45:54 +0900 (Tue, 29 Nov 2016) | 6 lines

Fix/improve documentation of String/Symbol#casecmp[?]

Fix documentation of String#casecmp? (examples didn't have the '?').
Add an example with non-ASCII characters. Clarify that casecmp,
unlike casecmp?, only does case-insensitivity on A-Z/a-z.
[ci skip]
------------------------------------------------------------------------
r56925 | shugo | 2016-11-29 17:44:21 +0900 (Tue, 29 Nov 2016) | 1 line

Suppress warnings.
------------------------------------------------------------------------
r56924 | duerst | 2016-11-29 17:39:57 +0900 (Tue, 29 Nov 2016) | 5 lines

Fix erroneous test of target against target

* test/ruby/enc/test_case_comprehensive.rb: fix test condition,
  add a temporary check for U+A64B, the only character where the tests
  currently fail. (Bug #12990)
------------------------------------------------------------------------
r56923 | shugo | 2016-11-29 17:31:39 +0900 (Tue, 29 Nov 2016) | 4 lines

Ignore SystemCallError in case it is raised by SSLSocket#accept.

Errno::ECONNRESET was raised by test_tls_post_connection_check and
test_tls_unknown_ca on mswin64 CI.
------------------------------------------------------------------------
r56922 | nobu | 2016-11-29 12:06:03 +0900 (Tue, 29 Nov 2016) | 4 lines

test_keyword.rb: more assertions

* test/ruby/test_keyword.rb (test_block_required_keyword): more
  assertions for positional and require keyword parameters.
------------------------------------------------------------------------
r56921 | nobu | 2016-11-29 12:06:02 +0900 (Tue, 29 Nov 2016) | 4 lines

test_keyword.rb: assert_raise_with_message value

* test/ruby/test_keyword.rb (test_block_required_keyword):
  assert_raise_with_message returns the raised exception object.
------------------------------------------------------------------------
r56920 | nobu | 2016-11-29 12:06:01 +0900 (Tue, 29 Nov 2016) | 4 lines

string.c: use xmalloc

* string.c (rb_str_casemap): use xmalloc simply instead of
  ALLOC_N.
------------------------------------------------------------------------
r56919 | shugo | 2016-11-29 11:47:11 +0900 (Tue, 29 Nov 2016) | 7 lines

net/ftp: add a new option ssl_handshake_timeout to Net::FTP.new.

The TLS handshake timeout can be specified independently, because the TLS
handshake doesn't start just after the underlying connection is established,
but after the AUTH command is completed.  It's also useful for testing
purposes.  However, if ssl_handshake_timeout is not specified, open_timeout
is used instead for convenience.
------------------------------------------------------------------------
r56918 | shugo | 2016-11-29 11:33:34 +0900 (Tue, 29 Nov 2016) | 3 lines

net/ftp: close the socket directly when an error occurs during TLS handshake.

Otherwise, @sock.read in Net::FTP#close hungs until read_timeout exceeded.
------------------------------------------------------------------------
r56917 | svn | 2016-11-29 11:21:51 +0900 (Tue, 29 Nov 2016) | 1 line

* 2016-11-29
------------------------------------------------------------------------
r56916 | shugo | 2016-11-29 11:21:50 +0900 (Tue, 29 Nov 2016) | 3 lines

net/ftp: close the connection if the TLS handshake timeout is exceeded.

Otherwise, file descriptor leaks may occur in Net::FTP.new.
------------------------------------------------------------------------
r56915 | nobu | 2016-11-28 22:16:00 +0900 (Mon, 28 Nov 2016) | 4 lines

string.c: fix zero-length array

* string.c (mapping_buffer): get rid of zero-length array member,
  which is not a part of C90.
------------------------------------------------------------------------
r56914 | usa | 2016-11-28 19:17:03 +0900 (Mon, 28 Nov 2016) | 4 lines

hide exceptions in server thread

* test/net/ftp/test_ftp.rb (test_tls_connect_timeout): sleeping to give a chance of complete of accept is a timing issue at all.  therefore, simply ignore the exception.

------------------------------------------------------------------------
r56913 | nobu | 2016-11-28 18:37:19 +0900 (Mon, 28 Nov 2016) | 4 lines

string.c: enable rdoc

* string.c (rb_str_casecmp_p): [DOC] move forward declaration of
  rb_str_downcase to enable rdoc.
------------------------------------------------------------------------
r56912 | duerst | 2016-11-28 17:37:32 +0900 (Mon, 28 Nov 2016) | 8 lines

implement String/Symbol#casecmp? including Unicode case folding

* string.c: Implement String#casecmp? and Symbol#casecmp? by using
  String#downcase :fold for Unicode case folding. This does not include
  options such as :turkic, because these currently cannot be combined
  with the :fold option. This implements feature #12786.

* test/ruby/test_string.rb/test_symbol.rb: Tests for above.
------------------------------------------------------------------------
r56911 | nobu | 2016-11-28 12:48:34 +0900 (Mon, 28 Nov 2016) | 4 lines

insns.def: adjust index type

* insns.def (checkmatch): adjust type of the index variable, to
  get rid of (potential) overflow.
------------------------------------------------------------------------
r56910 | usa | 2016-11-28 12:14:07 +0900 (Mon, 28 Nov 2016) | 4 lines

Give a chance to complete server.accept

* test/net/ftp/test_ftp.rb (test_tls_connect_timeout): get rid of a test error on Windows.

------------------------------------------------------------------------
r56909 | svn | 2016-11-28 11:02:41 +0900 (Mon, 28 Nov 2016) | 1 line

* 2016-11-28
------------------------------------------------------------------------
r56908 | nobu | 2016-11-28 11:02:40 +0900 (Mon, 28 Nov 2016) | 4 lines

compile.c: splatarray peephole opt

* compile.c (iseq_peephole_optimize): remove splatarray following
  always-array insn.
------------------------------------------------------------------------
r56907 | nobu | 2016-11-27 20:22:42 +0900 (Sun, 27 Nov 2016) | 5 lines

signal.c: improve stack overflow check

* signal.c (check_stack_overflow): [EXPERIMENTAL] consider the
  segfault a stack overflow when the fault address is between SP
  and BP.
------------------------------------------------------------------------
r56906 | nobu | 2016-11-27 20:07:27 +0900 (Sun, 27 Nov 2016) | 4 lines

object.c: no TypeError at special const dup

* object.c (rb_obj_dup): no longer raise a TypeError for special
  constants, and return itself instead.  [Feature#12979]
------------------------------------------------------------------------
r56905 | knu | 2016-11-27 19:08:00 +0900 (Sun, 27 Nov 2016) | 5 lines

Reverse compatibility_version and current_version for Darwin

The `compatibility_version` should have an API version and the
`current_version` should have a program version of Ruby, but they have
been reversed and the binary compatibility has never worked.
------------------------------------------------------------------------
r56904 | svn | 2016-11-27 18:40:52 +0900 (Sun, 27 Nov 2016) | 1 line

* 2016-11-27
------------------------------------------------------------------------
r56903 | ktsj | 2016-11-27 18:40:51 +0900 (Sun, 27 Nov 2016) | 1 line

gems/bundled_gems: Update to power_assert 0.4.1
------------------------------------------------------------------------
r56902 | nobu | 2016-11-26 20:37:01 +0900 (Sat, 26 Nov 2016) | 4 lines

file.c: home directory from system

* file.c (rb_default_home_dir): resolve home directory from the
  system database when HOME is not set.  [Feature #12695]
------------------------------------------------------------------------
r56901 | nobu | 2016-11-26 20:37:01 +0900 (Sat, 26 Nov 2016) | 4 lines

win32.c: special folders as home dir

* win32/win32.c (rb_w32_home_dir): move from win32/file.c to try
  special folders.
------------------------------------------------------------------------
r56900 | nobu | 2016-11-26 19:57:02 +0900 (Sat, 26 Nov 2016) | 1 line

NEWS: mention [Feature #12953] [ci skip]
------------------------------------------------------------------------
r56899 | svn | 2016-11-26 18:29:12 +0900 (Sat, 26 Nov 2016) | 1 line

* 2016-11-26
------------------------------------------------------------------------
r56898 | shugo | 2016-11-26 18:29:11 +0900 (Sat, 26 Nov 2016) | 3 lines

net/ftp: support timeout for TLS handshake.

Net::FTP inherits ssl_socket_connect from Net::Protocol to implement timeout.
------------------------------------------------------------------------
r56897 | nobu | 2016-11-25 15:28:00 +0900 (Fri, 25 Nov 2016) | 4 lines

round-down

* numeric.c (round_half_down, int_round_half_down): support
  round-down mode.
------------------------------------------------------------------------
r56896 | svn | 2016-11-25 05:51:46 +0900 (Fri, 25 Nov 2016) | 1 line

* 2016-11-25
------------------------------------------------------------------------
r56895 | usa | 2016-11-25 05:51:45 +0900 (Fri, 25 Nov 2016) | 4 lines

use `rb_struct_ptr` for `RSTRUCT_PTR` macro

* include/ruby/ruby.h (RSTRUCT_PTR): at r55788, `rb_struct_const_ptr` had been hidden and `rb_struct_ptr` had been implemented for backward compatiblity.  but the definition of `RSTRUCT_PTR` was not modified to use it, probably by mistake.

------------------------------------------------------------------------
r56894 | nobu | 2016-11-24 20:07:12 +0900 (Thu, 24 Nov 2016) | 5 lines

marshal.c: fix infinite recursion

* marshal.c (check_userdump_arg): marshal_dump should not return
  an instance of the same class, otherwise it causes infinite
  recursion.  [ruby-core:78289] [Bug #12974]
------------------------------------------------------------------------
r56893 | nobu | 2016-11-24 19:59:35 +0900 (Thu, 24 Nov 2016) | 4 lines

marshal.c: negative limit

* marshal.c (w_object): should not decrement negative limit which
  means unlimited.
------------------------------------------------------------------------
r56892 | nobu | 2016-11-24 12:01:59 +0900 (Thu, 24 Nov 2016) | 6 lines

test_fileutils.rb: fix deadlock

* test/fileutils/test_fileutils.rb (assert_output_lines): ensure
  that write pipe is closed, not the reader thread to deadlock
  when an exception raised in the given block.
  [ruby-core:78053] [Bug #12910]
------------------------------------------------------------------------
r56891 | shugo | 2016-11-24 10:03:07 +0900 (Thu, 24 Nov 2016) | 1 line

Add credit and PR/issue numbers.
------------------------------------------------------------------------
r56890 | normal | 2016-11-24 08:57:30 +0900 (Thu, 24 Nov 2016) | 7 lines

resolv: use safe navigation operator to avoid extra hash lookups

@addr2name is a private Hash and never changes its default_proc,
so only pay the hash lookup cost once; we know missing entries
in the hash will be nil.

* lib/resolv.rb (each_name): use safe navigation operator
------------------------------------------------------------------------
r56889 | normal | 2016-11-24 08:14:15 +0900 (Thu, 24 Nov 2016) | 6 lines

webrick/server: use symbol proc

Symbol proc is less code and avoids confusion from variable
naming.

* lib/webrick/server.rb (shutdown): use symbol proc
------------------------------------------------------------------------
r56886 | svn | 2016-11-24 00:10:20 +0900 (Thu, 24 Nov 2016) | 1 line

* 2016-11-24
------------------------------------------------------------------------
r56885 | shugo | 2016-11-24 00:10:19 +0900 (Thu, 24 Nov 2016) | 1 line

Add CR/LF check to Net::FTP#status.
------------------------------------------------------------------------
r56884 | nobu | 2016-11-23 20:30:02 +0900 (Wed, 23 Nov 2016) | 9 lines

test_fileutils.rb: Use primary group too

* test/fileutils/test_fileutils.rb (TestFileUtils#setup): Use
  primary group as well as supplementary groups.  based on the
  patch by V?\195?\173t Ondruch at [ruby-core:78053].  [Bug #12910]

It might happen in certain environments (systemd-nspawn) that
process has no supplementary groups, but primary groups should be
enough to pass most of the tests.
------------------------------------------------------------------------
r56883 | normal | 2016-11-23 17:10:44 +0900 (Wed, 23 Nov 2016) | 3 lines

lib/net/ftp: fix typo

* lib/net/ftp.rb (shutdown): fix typo
------------------------------------------------------------------------
r56882 | shugo | 2016-11-23 14:26:18 +0900 (Wed, 23 Nov 2016) | 4 lines

rescue Errno::EPROTOTYPE in FTPTest#test_list_read_timeout_exceeded.

Errno::EPROTOTYPE is sometimes raised on Mac OS X 10.10.
[ruby-core:78066] [Bug #12914]
------------------------------------------------------------------------
r56881 | shugo | 2016-11-23 13:40:40 +0900 (Wed, 23 Nov 2016) | 4 lines

Don't encode to UTF-8 if it's unnecessary.

If the file system encoding is ISO-8851-1 or if the encoding of the target
string is invalid, don't encode to UTF-8.  [ruby-core:78271] [Bug#12972]
------------------------------------------------------------------------
r56880 | shugo | 2016-11-23 09:34:13 +0900 (Wed, 23 Nov 2016) | 6 lines

Disconnect immediately even if Net::FTP#close is called without quit.

In that case, BufferedSSLSocket#read in FTP#close exceeded timeout because
BufferedSSLSocket#shutdown did nothing.  So BufferedIO#rbuf_fill is
overridden in BufferedSSLSocket to raise an EOFError if the connection is
shut down.
------------------------------------------------------------------------
r56879 | shugo | 2016-11-23 09:03:27 +0900 (Wed, 23 Nov 2016) | 4 lines

Add a new optinal argument pathname to FTP#stat.

Based on the patch by soleboxy.
[Fix GH-1478] [ruby-core:78240] [Feature #12965]
------------------------------------------------------------------------
r56878 | kazu | 2016-11-23 08:44:51 +0900 (Wed, 23 Nov 2016) | 1 line

Use `&.` instead of `if` and `? :`
------------------------------------------------------------------------
r56877 | nobu | 2016-11-23 08:32:44 +0900 (Wed, 23 Nov 2016) | 4 lines

parse.y: warn ? followed by a word

* parse.y (parse_qmark): warn `?` with unbalanced space, which is
  interpreted as a conditional operator.
------------------------------------------------------------------------
r56876 | svn | 2016-11-23 08:11:41 +0900 (Wed, 23 Nov 2016) | 1 line

* 2016-11-23
------------------------------------------------------------------------
r56875 | nobu | 2016-11-23 08:11:41 +0900 (Wed, 23 Nov 2016) | 1 line

Use `&.` and `||=` instead of if guards
------------------------------------------------------------------------
r56874 | kazu | 2016-11-22 22:59:16 +0900 (Tue, 22 Nov 2016) | 4 lines

IOError does not happen

* IOError does not happen even if another thread closes io
* Use symbol proc
------------------------------------------------------------------------
r56873 | kazu | 2016-11-22 22:11:43 +0900 (Tue, 22 Nov 2016) | 1 line

Use `&.` instead of modifier if
------------------------------------------------------------------------
r56872 | mrkn | 2016-11-22 14:21:12 +0900 (Tue, 22 Nov 2016) | 11 lines

complex.c: optimize f_gt_p some cases

* complex.c (f_gt_p): optimize f_gt_p for specific types of arguments.

* internal.h (rb_int_gt, rb_float_gt, rb_rational_cmp): exported.

* numeric.c (rb_float_gt): rename from flo_gt and be exported.

* numeric.c (rb_int_gt): rename from int_gt and be exported.

* rational.c (rb_rational_cmp): rename from nurat_cmp and be exported.
------------------------------------------------------------------------
r56871 | shugo | 2016-11-22 14:17:45 +0900 (Tue, 22 Nov 2016) | 4 lines

Add BufferedSSLSocket#send.

SSLSocket#send is not defined, so use #write instead.  flags and dest are
ignored.
------------------------------------------------------------------------
r56870 | mrkn | 2016-11-22 13:54:57 +0900 (Tue, 22 Nov 2016) | 5 lines

complex.c: optimize Kernel#Complex

* complex.c (nucomp_f_complex): use nucomp_s_convert directly.

* complex.c (id_convert): removed.
------------------------------------------------------------------------
r56869 | normal | 2016-11-22 09:16:23 +0900 (Tue, 22 Nov 2016) | 6 lines

webrick/server: simplify Daemon.start

Process.daemon exists since Ruby 1.9.1 and does most of what we need.

* lib/webrick/server.rb (Daemon.start): simplify
  [Misc #12937]
------------------------------------------------------------------------
r56868 | normal | 2016-11-22 08:50:31 +0900 (Tue, 22 Nov 2016) | 5 lines

resolv: use symbol proc when possible

This reduces both human code and bytecode.

lib/resolv.rb (sender_for, Config.parse_resolv_conf): use symbol proc
------------------------------------------------------------------------
r56867 | normal | 2016-11-22 08:50:25 +0900 (Tue, 22 Nov 2016) | 8 lines

socket: use symbol proc for IO#close loops

Made possible by r56795, this reduces human and byte code size.

* ext/socket/lib/socket.rb (self.ip_sockets_port0,
  self.tcp_server_sockets_port0,
  self.tcp_server_sockets,
  self.udp_server_sockets): use symbol proc
------------------------------------------------------------------------
r56866 | normal | 2016-11-22 08:13:16 +0900 (Tue, 22 Nov 2016) | 6 lines

lib/open3: favor symbol proc when possible

It reduces both human and machine code; as well as reducing
the confusion from variable naming.

* lib/open3.rb (popen_run, pipeline, pipeline_run): avoid capture
------------------------------------------------------------------------
r56865 | normal | 2016-11-22 08:05:41 +0900 (Tue, 22 Nov 2016) | 17 lines

lib/*: remove closed checks

Follow r56795.  Since Ruby 2.2, calling #close on a closed
socket no longer raises exceptions.

* lib/cgi/session.rb (update): remove closed? check
* lib/net/http.rb (finish, transport_request): ditto
* lib/net/imap.rb (disconnect): ditto
* lib/net/pop.rb (do_start, do_finish): ditto
* lib/net/smtp.rb (do_start, do_finish): ditto
* lib/open3.rb (popen_run, pipeline_run): ditto
* lib/pstore.rb (transaction): ditto
* lib/shell/process-controller.rb (sfork):
* lib/tempfile (_close, call, Tempfile.create): ditto
* lib/webrick/httpauth/htdigest.rb (flush): ditto
* lib/webrick/httpauth/htpasswd.rb (flush): ditto
* lib/webrick/server.rb (start_thread, cleanup_shutdown_pipe): ditto
------------------------------------------------------------------------
r56864 | svn | 2016-11-22 07:45:27 +0900 (Tue, 22 Nov 2016) | 1 line

* 2016-11-22
------------------------------------------------------------------------
r56863 | nobu | 2016-11-22 07:45:26 +0900 (Tue, 22 Nov 2016) | 3 lines

Revert r56856

* parse.y: tCHAR can be concatenated.
------------------------------------------------------------------------
r56862 | nobu | 2016-11-21 21:34:54 +0900 (Mon, 21 Nov 2016) | 4 lines

ftp.rb: fix typo [ci skip]

* lib/net/ftp.rb (Net::FTP#initialize): [DOC] fix type in option
  name, :username is used but :use is not.
------------------------------------------------------------------------
r56861 | shugo | 2016-11-21 19:38:31 +0900 (Mon, 21 Nov 2016) | 1 line

Add new options open_timeout and read_timeout to Net::FTP.new.
------------------------------------------------------------------------
r56860 | shugo | 2016-11-21 17:55:25 +0900 (Mon, 21 Nov 2016) | 1 line

Use dynamic dispatch instead of is_a?.
------------------------------------------------------------------------
r56857 | rhe | 2016-11-21 14:02:58 +0900 (Mon, 21 Nov 2016) | 13 lines

net/http: avoid writing/reading from unstarted SSL socket

When net/http connects to an HTTPS server through a CONNECT proxy, it
writes the CONNECT request to an unconnected OpenSSL::SSL::SSLSocket.

OpenSSL::SSL::SSLSocket traditionally fallbacks to a method call on the
underlying IO object if a read/write method is called before the TLS
connection is established. So it automagically works correctly, emitting
the "SSL session is not started yet" warning.

This is not obvious at first glance. The warning is also noisy. Let's
just write to the plain socket instead of relying on the SSLSocket's
behavior.
------------------------------------------------------------------------
r56856 | nobu | 2016-11-21 12:13:59 +0900 (Mon, 21 Nov 2016) | 4 lines

parse.y: tCHAR cannot be concatenated

* parse.y (strings): tCHAR is not a subject of string literal
  concatenation and string interpolation.
------------------------------------------------------------------------
r56855 | svn | 2016-11-21 11:17:29 +0900 (Mon, 21 Nov 2016) | 1 line

* 2016-11-21
------------------------------------------------------------------------
r56854 | nobu | 2016-11-21 11:17:29 +0900 (Mon, 21 Nov 2016) | 4 lines

numeric.c: refine error message

* numeric.c (rb_num_get_rounding_option): refine error message at
  invalid rounding mode.
------------------------------------------------------------------------
r56853 | nobu | 2016-11-20 19:52:28 +0900 (Sun, 20 Nov 2016) | 3 lines

proc.c: enable Proc#to_s rdoc

* proc.c (proc_to_s): move just after the rdoc comment.
------------------------------------------------------------------------
r56852 | nobu | 2016-11-20 19:41:09 +0900 (Sun, 20 Nov 2016) | 4 lines

proc.c: suppress warning

* proc.c (NO_CLOBBERED): suppress clobbered warning which appears
  only on mingw.
------------------------------------------------------------------------
r56851 | shugo | 2016-11-20 18:11:44 +0900 (Sun, 20 Nov 2016) | 1 line

Remove an unused variable to suppress a warning.
------------------------------------------------------------------------
r56850 | nobu | 2016-11-20 15:53:39 +0900 (Sun, 20 Nov 2016) | 4 lines

win32ole.c: suppress warnings

* ext/win32ole/win32ole.c (g_ole_initialized): compare with 0
  instead of cast to get rid of pointer-to-int-cast warnings.
------------------------------------------------------------------------
r56849 | usa | 2016-11-20 15:19:05 +0900 (Sun, 20 Nov 2016) | 5 lines

get rid of test failures introduced at r56848

* ext/rubyvm/lib/forwardable/impl.rb: remove an unused variable definition to
  get rid of a warning.

------------------------------------------------------------------------
r56848 | nobu | 2016-11-20 11:12:48 +0900 (Sun, 20 Nov 2016) | 5 lines

forwardable/impl.rb

* lib/forwardable/impl.rb (_valid_method?, _compile_method):
  extract to separate implementation specific part.
  [ruby-core:78138] [Bug #12938]
------------------------------------------------------------------------
r56847 | shugo | 2016-11-20 10:49:25 +0900 (Sun, 20 Nov 2016) | 3 lines

remote_address should be called on @bare_sock.

Because @sock.remote_address fails if @sock is an SSLSocket.
------------------------------------------------------------------------
r56846 | shugo | 2016-11-20 10:44:07 +0900 (Sun, 20 Nov 2016) | 4 lines

shutdown(2) should not be called for SSLSocket.

SSLSocket#stop is a private method and cannot be called, but explicit calls
are not necessary because SSL_shutdown() is called from SSLSocket#close.
------------------------------------------------------------------------
r56845 | svn | 2016-11-20 08:51:50 +0900 (Sun, 20 Nov 2016) | 1 line

* 2016-11-20
------------------------------------------------------------------------
r56844 | suke | 2016-11-20 08:51:49 +0900 (Sun, 20 Nov 2016) | 3 lines

* ext/win32ole/win32ole.c: independent of libgcc_s_seh-1.dll [Bug #12959] 
  Thanks to Tsuyoshi Morita for bug report.

------------------------------------------------------------------------
r56843 | shugo | 2016-11-19 20:01:55 +0900 (Sat, 19 Nov 2016) | 1 line

Use Socket instead of TCPSocket/TCPServer.
------------------------------------------------------------------------
r56842 | shugo | 2016-11-19 16:02:32 +0900 (Sat, 19 Nov 2016) | 1 line

Expand abbreviated option names.
------------------------------------------------------------------------
r56840 | nobu | 2016-11-19 13:32:52 +0900 (Sat, 19 Nov 2016) | 4 lines

ruby.h: rb_big_sign

* include/ruby/ruby.h (RBIGNUM_SIGN): use a wrapper function to
  return the sign bit, instead of comparing with 0.
------------------------------------------------------------------------
r56839 | shugo | 2016-11-19 13:19:35 +0900 (Sat, 19 Nov 2016) | 1 line

Shut down TLS connections gracefully.
------------------------------------------------------------------------
r56837 | shugo | 2016-11-19 11:40:33 +0900 (Sat, 19 Nov 2016) | 1 line

Remove garbage.
------------------------------------------------------------------------
r56836 | shugo | 2016-11-19 11:37:39 +0900 (Sat, 19 Nov 2016) | 1 line

Move certificates to test/net/fixtures/.
------------------------------------------------------------------------
r56835 | svn | 2016-11-19 11:29:24 +0900 (Sat, 19 Nov 2016) | 1 line

* remove trailing spaces.
------------------------------------------------------------------------
r56834 | shugo | 2016-11-19 11:29:23 +0900 (Sat, 19 Nov 2016) | 5 lines

Support TLS and hash styles options for Net::FTP.new.

If the :ssl options is specified, the control connection is protected with
TLS in the manner described in RFC 4217.  Data connections are also
protected with TLS unless the :private_data_connection is set to false.
------------------------------------------------------------------------
r56833 | nobu | 2016-11-19 10:55:34 +0900 (Sat, 19 Nov 2016) | 4 lines

math.c: unused_obj

* math.c (exp1, exp2): use immediate 0 instead of rb_mMath, which
  is never used.
------------------------------------------------------------------------
r56832 | nobu | 2016-11-19 10:16:50 +0900 (Sat, 19 Nov 2016) | 5 lines

dln.c: raise LoadError

* dln.c (dln_load): raise LoadError instead of fatal error on
  recent OSX, dlclose seems fixed in El Capitan or later.
  [ruby-core:78200] [Bug #12956]
------------------------------------------------------------------------
r56831 | tadd | 2016-11-19 00:31:05 +0900 (Sat, 19 Nov 2016) | 2 lines

* NEWS: Added entry for optimized Rational. [Feature #12484] [ci skip]

------------------------------------------------------------------------
r56830 | mrkn | 2016-11-19 00:17:19 +0900 (Sat, 19 Nov 2016) | 13 lines

complex.c: optimize f_negate

* complex.c (f_negate): optimize for special numeric types.

* complex.c (nucomp_expt): use rb_int_uminus instead of f_negate for
  fixnum value.

* internal.h (rb_float_uminus, rb_rational_uminus): exported.

* numeric.c (rb_float_uminus): rename from flo_uminus.

* rational.c (rb_rational_uminus): rename from nurat_negate, and add
  assertion for the parameter.
------------------------------------------------------------------------
r56829 | svn | 2016-11-19 00:04:37 +0900 (Sat, 19 Nov 2016) | 1 line

* 2016-11-19
------------------------------------------------------------------------
r56828 | mrkn | 2016-11-19 00:04:36 +0900 (Sat, 19 Nov 2016) | 8 lines

rational.c: optimization and refactoring

* rational.c (nurat_s_new_bang, nurat_canonicalize): small optimization
  by using rb_int_uminus instead of f_negate.

* rational.c (nurat_canonicalize): add assertions for parameters.

* rational.c (f_negate, id_negate): removed.
------------------------------------------------------------------------
r56827 | mrkn | 2016-11-18 23:24:15 +0900 (Fri, 18 Nov 2016) | 7 lines

complex.c: refactoring

* complex.c (nucomp_abs): use rb_math_hypot directly.

* complex.c (nucomp_arg): use rb_math_atan2 directly.

* complex.c (imp2, m_{atan2,hypot}_bang, m_hypot): removed.
------------------------------------------------------------------------
r56826 | yui-knk | 2016-11-18 20:05:20 +0900 (Fri, 18 Nov 2016) | 3 lines

objspace.c:: indent [ci skip]

* ext/objspace/objspace.c (memsize_of_m): adjust indent of comments.
------------------------------------------------------------------------
r56825 | yui-knk | 2016-11-18 19:58:30 +0900 (Fri, 18 Nov 2016) | 1 line

* NEWS: Fix class name
------------------------------------------------------------------------
r56824 | nobu | 2016-11-18 15:29:51 +0900 (Fri, 18 Nov 2016) | 4 lines

internal.h: round macros

* internal.h (ROUND_FUNC, ROUND_CALL): macros wrapping round
  functions.
------------------------------------------------------------------------
r56823 | svn | 2016-11-18 13:34:27 +0900 (Fri, 18 Nov 2016) | 1 line

* 2016-11-18
------------------------------------------------------------------------
r56822 | nobu | 2016-11-18 13:34:26 +0900 (Fri, 18 Nov 2016) | 6 lines

extmk.rb: removed compiled? method [ci skip]

* ext/extmk.rb (compiled?): removed.

* ext/win32/extconf.rb: try to install libraries regardless
  fiddle.
------------------------------------------------------------------------
r56821 | hsbt | 2016-11-17 22:05:46 +0900 (Thu, 17 Nov 2016) | 12 lines

Remove webhook notification to Travis CI [skip ci]

  As travis-rubies now uses 3 Mac jobs to create archives for various OS
  releases.

  This is a bit wasteful if multiple builds pass in a short period.

  Instead, Travis CI is now running a nightly build of ruby-head
  (around 22:30 UTC). This will happen regardless of the state of the
  master branch.

  Author: Hiro Asari <asari.ruby@gmail.com>
------------------------------------------------------------------------
r56820 | nobu | 2016-11-17 20:52:11 +0900 (Thu, 17 Nov 2016) | 4 lines

readline.c: str_subpos

* ext/readline/readline.c (str_subpos): make string instance only
  if necessary.
------------------------------------------------------------------------
r56819 | usa | 2016-11-17 17:50:36 +0900 (Thu, 17 Nov 2016) | 4 lines

numeric.c: get rid of a compile error on mingw64

* numeric.c (rb_fix2str): typo.

------------------------------------------------------------------------
r56818 | svn | 2016-11-17 16:19:50 +0900 (Thu, 17 Nov 2016) | 1 line

* 2016-11-17
------------------------------------------------------------------------
r56817 | shugo | 2016-11-17 16:19:49 +0900 (Thu, 17 Nov 2016) | 4 lines

mkconfig.rb: add a magic comment to rbconfig.rb

* tool/mkconfig.rb: add a magic comment to rbconfig.rb in case the command
  line option -K is specified.  [ruby-core:78181] [Bug #12949]
------------------------------------------------------------------------
r56815 | nobu | 2016-11-16 15:59:42 +0900 (Wed, 16 Nov 2016) | 7 lines

logger.rb: fix next rotate time

* lib/logger.rb (Logger::LogDevice#initialize): calculate next
  rotate time based on the mtime of the last existing file.
  [ruby-dev:49881] [Bug #12948]

Author: Tsukasa Oishi <tsukasa.oishi@gmail.com>
------------------------------------------------------------------------
r56814 | nobu | 2016-11-16 15:59:41 +0900 (Wed, 16 Nov 2016) | 1 line

test/logger/test_logdevice.rb: heredoc styles
------------------------------------------------------------------------
r56813 | nobu | 2016-11-16 15:59:40 +0900 (Wed, 16 Nov 2016) | 5 lines

ruby-additional.el: unquoted code block

* misc/ruby-additional.el (ruby-insert-heredoc-code-block): make
  code between "begin;" and "end;" unquoted.  still quotable
  before "begin;".
------------------------------------------------------------------------
r56812 | nobu | 2016-11-16 15:07:55 +0900 (Wed, 16 Nov 2016) | 4 lines

configure.in: compressed debug section option

* configure.in: make compressed debug section optional.
  [ruby-core:78121] [Bug #12934]
------------------------------------------------------------------------
r56811 | nobu | 2016-11-16 14:25:53 +0900 (Wed, 16 Nov 2016) | 4 lines

test_flip.rb: r56316

* test/ruby/test_flip.rb (test_input_line_number_range): test for
  r56316.  [ruby-core:78162] [Bug #12947]
------------------------------------------------------------------------
r56810 | mrkn | 2016-11-16 13:25:37 +0900 (Wed, 16 Nov 2016) | 4 lines

math.c: remove needless ifdef clause

* math.c (ifdef M_PI): M_PI is eventually defined in missing.h even if math.h
  doesn't supply it.
------------------------------------------------------------------------
r56809 | mrkn | 2016-11-16 13:25:35 +0900 (Wed, 16 Nov 2016) | 16 lines

complex.c: optimize Numeric#polar and Numeric#arg

* complex.c (numeric_polar): optimize for Integer, Float, and Rational.

* complex.c (numeric_arg): directly create the value of pi.

* complex.c (f_negative_p): optimize for Integer, Float, and Rational.

* rational.c (INT_NEGATIVE_P): move the definition into internal.h.

* internal.h (INT_NEGATIVE_P): ditto.

* numeric.c (rb_float_abs): rename from flo_abs and export to be used
  from other source files..

* internal.h (rb_float_abs): ditto.
------------------------------------------------------------------------
r56808 | mrkn | 2016-11-16 13:25:33 +0900 (Wed, 16 Nov 2016) | 4 lines

rational.c: optimize Rational#abs

* rational.c (rb_rational_abs): optimize Rational#abs with the
  specialized implementation.
------------------------------------------------------------------------
r56807 | hsbt | 2016-11-16 12:02:42 +0900 (Wed, 16 Nov 2016) | 3 lines

Fix a typo.

https://github.com/ruby/psych/commit/18d13b1df09504548feb4cb9b259fed552d6a4d5
------------------------------------------------------------------------
r56806 | hsbt | 2016-11-16 11:51:26 +0900 (Wed, 16 Nov 2016) | 4 lines

Fixed regression of typo fix.

Picked from upstream: https://github.com/ruby/psych/commit/66fb7fb77533d0606748940288858794752d95cb
[ci skip][ruby-dev:49879][Bug #12942]
------------------------------------------------------------------------
r56805 | svn | 2016-11-16 00:04:57 +0900 (Wed, 16 Nov 2016) | 1 line

* 2016-11-16
------------------------------------------------------------------------
r56804 | kazu | 2016-11-16 00:04:56 +0900 (Wed, 16 Nov 2016) | 1 line

Fix regexp and typo
------------------------------------------------------------------------
r56801 | naruse | 2016-11-15 21:42:04 +0900 (Tue, 15 Nov 2016) | 3 lines

Use rb_mod_name instead of classname

classname() is static function.
------------------------------------------------------------------------
r56799 | shugo | 2016-11-15 17:16:45 +0900 (Tue, 15 Nov 2016) | 1 line

ftp.rb: use Addrinfo interfaces
------------------------------------------------------------------------
r56797 | nobu | 2016-11-15 15:28:05 +0900 (Tue, 15 Nov 2016) | 6 lines

complex.c: purge id_eqeq_p and limit return value

* complex.c (f_eqeq_p): use rb_equal.

* complex.c (nucomp_eqeq_p): limit return value to true or false,
  instead of the result of the other as-is.
------------------------------------------------------------------------
r56795 | nobu | 2016-11-15 10:39:11 +0900 (Tue, 15 Nov 2016) | 4 lines

socket.rb: remove closed checks

* ext/socket/lib/socket.rb: remove unnecessary closed checks,
  close on closed socket no longer raises an exception.
------------------------------------------------------------------------
r56794 | nobu | 2016-11-15 10:39:10 +0900 (Tue, 15 Nov 2016) | 4 lines

ftp.rb: use Addrinfo

* lib/net/ftp.rb (sendport, makeport, makepasv, BufferedSocket):
  use Addrinfo interfaces.
------------------------------------------------------------------------
r56793 | normal | 2016-11-15 09:27:20 +0900 (Tue, 15 Nov 2016) | 11 lines

st.c: fix crashes on huge hash tables

From: Vladimir Makarov <vmakarov@redhat.com>

By Vladimir's estimation, this requires at least 64 GB of memory
to reproduce this bug due to the hash sizes required.  So there
is no new test case (and I am unable to test it, myself).

* st.c (get_bins_num): avoid out-of-bounds on shift by using correct type
  [ruby-core:78139] [Bug #12939]
* st.c (get_allocated_entries): ditto
------------------------------------------------------------------------
r56792 | headius | 2016-11-15 04:39:21 +0900 (Tue, 15 Nov 2016) | 2 lines

* test/thread/test_queue.rb: Give up to ten seconds for threads to
  reach expected state before proceeding.
------------------------------------------------------------------------
r56791 | svn | 2016-11-15 04:27:25 +0900 (Tue, 15 Nov 2016) | 1 line

* 2016-11-15
------------------------------------------------------------------------
r56790 | headius | 2016-11-15 04:27:24 +0900 (Tue, 15 Nov 2016) | 5 lines

* test/ruby/test_module.rb: Method tables are not guaranteed to be
  ordered.
* test/ruby/test_struct.rb: Ditto.
* test/ruby/test_thread.rb: Thread locals are not guaranteed to be
ordered.
------------------------------------------------------------------------
r56780 | nobu | 2016-11-14 16:59:50 +0900 (Mon, 14 Nov 2016) | 3 lines

net/ftp.rb: kwargs

* lib/net/ftp.rb (Net::FTP#open_socket): use keyword argument.
------------------------------------------------------------------------
r56779 | nobu | 2016-11-14 16:53:32 +0900 (Mon, 14 Nov 2016) | 4 lines

net/protocol.rb: kwargs

* lib/net/protocol.rb (Net::BufferedIO#initialize): add keyword
  arguments for initial attributes.
------------------------------------------------------------------------
r56778 | nobu | 2016-11-14 16:53:31 +0900 (Mon, 14 Nov 2016) | 6 lines

socket.rb: kwargs

* ext/socket/lib/socket.rb (connect_{from,to}, connect): let use
  keyword arguments.

* ext/socket/lib/socket.rb (Socket.tcp): ditto.
------------------------------------------------------------------------
r56777 | nobu | 2016-11-14 14:17:55 +0900 (Mon, 14 Nov 2016) | 4 lines

vm_eval.c: fstring instance_eval

* vm_eval.c (singleton_class_for_eval): enable fstring singleton
  class for instance_eval.  [ruby-core:78116] [Bug #12930]
------------------------------------------------------------------------
r56776 | nobu | 2016-11-14 13:06:15 +0900 (Mon, 14 Nov 2016) | 8 lines

complex.c: optimize

* complex.c (f_negative_p): use rb_num_negative_p instead of funcall.

* complex.c (f_kind_of_p, f_numeric_p): cast down to int because
  rb_obj_is_kind_of is safe.

* complex.c (f_signbit, f_tpositive_p): remove f_boolcast.
------------------------------------------------------------------------
r56775 | nobu | 2016-11-14 13:02:45 +0900 (Mon, 14 Nov 2016) | 4 lines

rational.c: cast to int

* rational.c (f_kind_of_p): rb_obj_is_kind_of returns Qtrue or
  Qfalse always, and is safe to cast down to int.
------------------------------------------------------------------------
r56774 | svn | 2016-11-14 09:40:06 +0900 (Mon, 14 Nov 2016) | 1 line

* remove trailing spaces.
------------------------------------------------------------------------
r56773 | hsbt | 2016-11-14 09:40:04 +0900 (Mon, 14 Nov 2016) | 4 lines

Update bundled psych to 2.2.0.

 * Merge libyaml-0.1.7 for bundled-libyaml option.
 * Update canonical url to https://github.com/ruby/psych.
------------------------------------------------------------------------
r56772 | mrkn | 2016-11-14 01:43:43 +0900 (Mon, 14 Nov 2016) | 5 lines

complex.c: refactoring

* complex.c (f_zero_p): return int rather than VALUE.

* complex.c (rb_complex_mul): remove needless negate operations.
------------------------------------------------------------------------
r56771 | mrkn | 2016-11-14 01:22:26 +0900 (Mon, 14 Nov 2016) | 3 lines

complex.c: refactoring

* complex.c (f_one_p): removed.
------------------------------------------------------------------------
r56770 | mrkn | 2016-11-14 01:22:08 +0900 (Mon, 14 Nov 2016) | 6 lines

complex.c: refactoring and small optimization

* complex.c (nucomp_expt): optimize the access to the numerator and
  denominator of a rational number.

* complex.c (k_rational_p): removed.
------------------------------------------------------------------------
r56769 | svn | 2016-11-14 01:21:55 +0900 (Mon, 14 Nov 2016) | 1 line

* 2016-11-14
------------------------------------------------------------------------
r56768 | mrkn | 2016-11-14 01:21:54 +0900 (Mon, 14 Nov 2016) | 3 lines

complex.c: refactoring

* complex.c (f_addsub, k_complex_p, k_float_p): removed.
------------------------------------------------------------------------
r56767 | nobu | 2016-11-13 14:25:54 +0900 (Sun, 13 Nov 2016) | 7 lines

error.c: redefined backtrace

* error.c (rb_get_backtrace): honor redefined Exception#backtrace
  method.  [ruby-core:78097] [Bug #12925]

* eval.c (setup_exception): rescue exceptions during backtrace
  setup.
------------------------------------------------------------------------
r56766 | nobu | 2016-11-13 14:25:53 +0900 (Sun, 13 Nov 2016) | 4 lines

error.c: rb_get_backtrace

* error.c (rb_get_backtrace): move from eval_error.c to call
  exc_backtrace directly.  [ruby-core:78097] [Bug #12925]
------------------------------------------------------------------------
r56765 | nobu | 2016-11-13 11:11:07 +0900 (Sun, 13 Nov 2016) | 7 lines

readline: remove dependency on internal.h

* ext/readline/depend: remove dependency on internal.h.

* ext/readline/readline.c (readline_s_delete_text): use
  rb_enc_str_new_static instead of rb_setup_fake_str not to depend
  on internal.h.
------------------------------------------------------------------------
r56764 | nobu | 2016-11-13 11:04:51 +0900 (Sun, 13 Nov 2016) | 4 lines

numeric.c: limit return value

* numeric.c (num_equal): limit return value to true or false,
  instead of the result of the other as-is.
------------------------------------------------------------------------
r56763 | nobu | 2016-11-13 10:51:29 +0900 (Sun, 13 Nov 2016) | 5 lines

purge id_eqeq_p

* rational.c (f_{eqeq,zero,one,minus_one}_p, nurat_eqeq_p): use
  rb_equal.  this function returns Qtrue or Qfalse always, so it
  is safe to cast down to int.
------------------------------------------------------------------------
r56762 | mrkn | 2016-11-13 03:42:30 +0900 (Sun, 13 Nov 2016) | 6 lines

complex.c: refactoring

* complex.c: refactor to use some specific macros and
  to reduce needless conversion by FIX2LONG.

* complex.c (k_fixnum_p, k_bignum_p): removed.
------------------------------------------------------------------------
r56761 | mrkn | 2016-11-13 01:29:11 +0900 (Sun, 13 Nov 2016) | 3 lines

rational.c: refactoring

* rational.c: use RB_INTEGER_TYPE_P, RB_FLOAT_TYPE_P, and FIXNUM_ZERO_P.
------------------------------------------------------------------------
r56760 | mrkn | 2016-11-13 00:43:34 +0900 (Sun, 13 Nov 2016) | 3 lines

rational.c: remove f_negative_p

* rational.c (f_negative_p): removed.
------------------------------------------------------------------------
r56759 | mrkn | 2016-11-13 00:43:26 +0900 (Sun, 13 Nov 2016) | 8 lines

rational.c: optimize Integer#lcm

* rational.c (f_div, f_mul, f_abs): optimize Integer#lcm
  Author: Tadashi Saito <tad.a.digger@gmail.com>

* numeric.c (rb_int_abs): rename from int_abs to be exported.

* internal.h (rb_int_div, rb_int_abs): exported.
------------------------------------------------------------------------
r56758 | mrkn | 2016-11-13 00:43:18 +0900 (Sun, 13 Nov 2016) | 4 lines

rational.c: optimize (-rational).rationalize(some)

* rational.c (nurat_rationalize): optimize (-rational).rationalize(some).
  Author: Tadashi Saito <tad.a.digger@gmail.com>
------------------------------------------------------------------------
r56757 | svn | 2016-11-13 00:07:53 +0900 (Sun, 13 Nov 2016) | 1 line

* 2016-11-13
------------------------------------------------------------------------
r56756 | mrkn | 2016-11-13 00:07:53 +0900 (Sun, 13 Nov 2016) | 5 lines

rational.c: define Rational#{negative?,positive?}

* rational.c (nurat_{negative,positive}_p): define Rational#negative?
  and Rational#positive?, respectively.
  Author: Tadashi Saito <tad.a.digger@gmail.com>
------------------------------------------------------------------------
r56755 | mrkn | 2016-11-12 23:54:19 +0900 (Sat, 12 Nov 2016) | 4 lines

rational.c: refactoring

* rational.c (id_expt, id_fdiv, f_expt, f_fdiv, f_positive_p): removed.
  Author: Tadashi Saito <tad.a.digger@gmail.com>
------------------------------------------------------------------------
r56754 | nobu | 2016-11-12 22:24:23 +0900 (Sat, 12 Nov 2016) | 4 lines

test_fstring.rb: fix exception

* test/-ext-/string/test_fstring.rb (test_singleton_class): fix
  expected exception class.  [ruby-dev:49867] [Bug #12923]
------------------------------------------------------------------------
r56753 | mrkn | 2016-11-12 21:16:12 +0900 (Sat, 12 Nov 2016) | 3 lines

raitonal.c: remove needless macro

* rational.c (id_lshift, f_lshift): removed.
------------------------------------------------------------------------
r56752 | mrkn | 2016-11-12 21:14:10 +0900 (Sat, 12 Nov 2016) | 5 lines

rational.c: optimize Float#rationalize

* rational.c (rb_flt_rationalize{,_with_prec},float_rationalize):
  optimize Float#rationalize.
  Author: Tadashi Saito <tad.a.digger@gmail.com>
------------------------------------------------------------------------
r56751 | mrkn | 2016-11-12 20:52:09 +0900 (Sat, 12 Nov 2016) | 4 lines

rational.c: use rb_num_zerodiv instead of rb_raise_zerodiv

* rational.c (rb_raize_zerodiv): replace by rb_num_zerodiv.
  Author: Tadashi Saito <tad.a.digger@gmail.com>
------------------------------------------------------------------------
r56750 | mrkn | 2016-11-12 20:52:00 +0900 (Sat, 12 Nov 2016) | 7 lines

rational.c: optimize Float#to_r

* rational.c (float_to_r): optimize Float#to_r.

* numeric.c (rb_int_lshift): exported.

* internal.h (rb_int_lshift): ditto.
------------------------------------------------------------------------
r56749 | mrkn | 2016-11-12 20:51:51 +0900 (Sat, 12 Nov 2016) | 5 lines

rational.c: optimize Float#{numerator,denominator}

* rational.c (float_{numerator,denominator}): optimize
  Float#{numerator,denominator}.
  Author: Tadashi Saito <tad.a.digger@gmail.com>
------------------------------------------------------------------------
r56748 | mrkn | 2016-11-12 20:51:41 +0900 (Sat, 12 Nov 2016) | 4 lines

rational.c: optimize Numeric#quo

* rational.c (numeric_quo): optimize Numeric#quo.
  Author: Tadashi Saito <tad.a.digger@gmail.com>
------------------------------------------------------------------------
r56747 | nobu | 2016-11-12 18:43:05 +0900 (Sat, 12 Nov 2016) | 5 lines

class.c: no fstring singleton class

* class.c (singleton_class_of): prohibit fstrings from creating
  singleton classes.
  temporary measure for [ruby-dev:49867] [Bug #12923]
------------------------------------------------------------------------
r56746 | nobu | 2016-11-12 17:16:58 +0900 (Sat, 12 Nov 2016) | 4 lines

symbol/noninterned_name.rb

* test/-ext-/symbol/noninterned_name.rb: split from
  test_inadvertent_creation.rb.
------------------------------------------------------------------------
r56745 | mrkn | 2016-11-12 16:32:28 +0900 (Sat, 12 Nov 2016) | 3 lines

rational.c: refactor by removing needless ID vars

* rational.c (id_cmp, id_trunate): removed.
------------------------------------------------------------------------
r56744 | mrkn | 2016-11-12 16:28:47 +0900 (Sat, 12 Nov 2016) | 8 lines

rational.c: optimize Rational#fdiv

* rational.c (nurat_fdiv): optimize Rational#fdiv.
  Author: Tadashi Saito <tad.a.digger@gmail.com>

* rational.c (f_to_f, id_to_f): removed.

* rational.c (f_expt): only used when FLT_RADIX is not 2.
------------------------------------------------------------------------
r56743 | mrkn | 2016-11-12 15:58:35 +0900 (Sat, 12 Nov 2016) | 4 lines

rational.c: optimize Rational#to_i

* rational.c (nurat_truncate): optimize Rational#to_i.
  Author: Tadashi Saito <tad.a.digger@gmail.com>
------------------------------------------------------------------------
r56742 | mrkn | 2016-11-12 15:45:11 +0900 (Sat, 12 Nov 2016) | 11 lines

rational.c: optimize Rational#{floor,ceil,round,truncate}

* rational.c (f_{expt10,round_common},nurat_{floor,ceil,round_half_{up,even}}):
  optimize Rational#{floor,ceil,round,truncate}.
  Author: Tadashi Saito <tad.a.digger@gmail.com>

* numeric.c (rb_int_divmod): rename from int_divmod to be exported.

* numeric.c (rb_int_and): rename from int_and to be exported.

* intern.h (rb_int_{divmod,and}): exported.
------------------------------------------------------------------------
r56741 | mrkn | 2016-11-12 15:17:12 +0900 (Sat, 12 Nov 2016) | 5 lines

rational.c: optimize rational.coerce(float) and float [+-*/] rational

* rational.c (nurat_coerce): optimize rational.coerce(float).
  note that this makes `float [+-*/] rational` faster
  Author: Tadashi Saito <tad.a.digger@gmail.com>
------------------------------------------------------------------------
r56740 | nobu | 2016-11-12 15:12:13 +0900 (Sat, 12 Nov 2016) | 7 lines

pack.c: simplify

* pack.c (str_associate): remove unnecessary branch.
  the argument must be a plain vanilla string object.

* pack.c (str_associated): use rb_ivar_lookup to give the
  undefined value.
------------------------------------------------------------------------
r56739 | nobu | 2016-11-12 15:12:12 +0900 (Sat, 12 Nov 2016) | 4 lines

class.c: trivial optimization

* class.c (singleton_class_of): just copy FROZEN flag without
  conditions.
------------------------------------------------------------------------
r56738 | nobu | 2016-11-12 15:12:09 +0900 (Sat, 12 Nov 2016) | 4 lines

.gdbinit: improve rp [ci skip]

* .gdbinit (rp): improve T_OBJECT dump.  show the contents of the
  instance variables table.
------------------------------------------------------------------------
r56737 | mrkn | 2016-11-12 15:07:46 +0900 (Sat, 12 Nov 2016) | 9 lines

rational.c: optimize construction of Rational

* rational.c (nurat_{s_new_bang,canonicalize,f_rational,s_convert}):
  optimize construction of Rational from numbers.
  Author: Tadashi Saito <tad.a.digger@gmail.com>

* rational.c (read_{num,rat_nos}): optimize construction of Rational
  from string.
  Author: Tadashi Saito <tad.a.digger@gmail.com>
------------------------------------------------------------------------
r56736 | mrkn | 2016-11-12 15:07:24 +0900 (Sat, 12 Nov 2016) | 10 lines

rational.c: purge f_cmp

* rational.c (f_cmp, nurat_expt): purge f_cmp.
  Author: Tadashi Saito <tad.a.digger@gmail.com>

* rational.c (INT_POSITIVE_P): added.

* numeric.c (FIXNUM_POSITIVE_P): move the definition into internal.h.

* internal.h (FIXNUM_POSITIVE_P): ditto.
------------------------------------------------------------------------
r56735 | mrkn | 2016-11-12 15:07:01 +0900 (Sat, 12 Nov 2016) | 4 lines

rational.c: optimize Rational#-@

* rational.c (nurat_negate): introduced to optimize Rational#-@.
  Author: Tadashi Saito <tad.a.digger@gmail.com>
------------------------------------------------------------------------
r56734 | mrkn | 2016-11-12 11:24:32 +0900 (Sat, 12 Nov 2016) | 9 lines

rational.c: optimize Rational#==

* rational.c (nurat_eqeq_p): optimize Rational#==.
  Author: Tadashi Saito <tad.a.digger@gmail.com>

* numeric.c (rb_int_equal): rename from int_equal and remove static
  to be exported.

* internal.h (rb_int_equal): exported.
------------------------------------------------------------------------
r56733 | mrkn | 2016-11-12 10:29:01 +0900 (Sat, 12 Nov 2016) | 9 lines

rational.c: optimize Rational#<=>

* rational.c (nurat_cmp): optimize Rational#<=>.
  Author: Tadashi Saito <tad.a.digger@gmail.com>

* numeric.c (rb_int_cmp): rename from int_cmp and remove static
  to be exported.

* internal.h (rb_int_cmp): exported.
------------------------------------------------------------------------
r56725 | mrkn | 2016-11-12 01:38:28 +0900 (Sat, 12 Nov 2016) | 9 lines

rational.c: optimize Rational#**

* rational.c (nurat_expt): optimize Rational#**.
  Author: Tadashi Saito <tad.a.digger@gmail.com>

* numeric.c (rb_float_pow): rename flo_pow() to rb_float_pow()
  and remove static to be exporetd.

* internal.h (rb_int_pow, rb_float_pow): exported.
------------------------------------------------------------------------
r56724 | mrkn | 2016-11-12 01:18:13 +0900 (Sat, 12 Nov 2016) | 3 lines

rational.c: add argument type check assertions in f_muldiv

* rational.c (f_muldiv): add assertions to check argument types
------------------------------------------------------------------------
r56723 | mrkn | 2016-11-12 01:17:56 +0900 (Sat, 12 Nov 2016) | 4 lines

rational.c: optimize Rational#/

* rational.c (f_muldiv, nurat_div): optimize Rational#/.
  Author: Tadashi Saito <tad.a.digger@gmail.com>
------------------------------------------------------------------------
r56719 | mrkn | 2016-11-12 00:55:30 +0900 (Sat, 12 Nov 2016) | 25 lines

rational.c: avoid needless object allocation with nurat_to_double

* rational.c (nurat_to_double): introduce to convert rational to double
  without object allocation.

* rational.c (rb_rational_plus, nurat_{sub,mul,to_f}): rewrite by using
  nurat_to_double.

* bignum.c (rb_big_fdiv_double): introduce to calculate fdiv and return
  the result as a double value.

* bignum.c (big_fdiv{,_int,_float}): change the return types for
  implementing rb_big_fdiv_double.

* bignum.c (rb_big_fdiv): rewrite by using rb_big_fdiv_double.

* numeric.c (rb_int_fdiv_double): introduce to calculate fdiv and return
  the result as a double value.

* numeric.c (fix_fdiv_double): rewrite from fix_fdiv to return the
  result as a double value.

* numeric.c (rb_int_fdiv): rewrite by using rb_int_fdiv_double.

* internal.h (rb_{big,int}_fdiv_double): exported.
------------------------------------------------------------------------
r56716 | nagachika | 2016-11-12 00:43:43 +0900 (Sat, 12 Nov 2016) | 2 lines

fix a constant name typo in redmine-backporter.rb
[ci skip]
------------------------------------------------------------------------
r56713 | svn | 2016-11-12 00:11:05 +0900 (Sat, 12 Nov 2016) | 1 line

* 2016-11-12
------------------------------------------------------------------------
r56712 | mrkn | 2016-11-12 00:11:04 +0900 (Sat, 12 Nov 2016) | 5 lines

rational.c: optimize rational * {float, huge rational, bignum}

* rational.c (f_muldiv, nurat_mul):
  optimize rational * {float, huge rational, bignum}.
  Author: Tadashi Saito <tad.a.digger@gmail.com>
------------------------------------------------------------------------
r56711 | mrkn | 2016-11-11 23:57:11 +0900 (Fri, 11 Nov 2016) | 4 lines

rational.c: optimize rational - {float,rational}

* rational.c (f_addsub, nurat_sub): optimize rational - {float,rational}.
  Author: Tadashi Saito <tad.a.digger@gmail.com>
------------------------------------------------------------------------
r56710 | mrkn | 2016-11-11 23:45:11 +0900 (Fri, 11 Nov 2016) | 4 lines

rational.c: optimize rational - integer

* rational.c (nurat_sub): optimize rational - integer.
  Author: Tadashi Saito <tad.a.digger@gmail.com>
------------------------------------------------------------------------
r56709 | mrkn | 2016-11-11 23:42:53 +0900 (Fri, 11 Nov 2016) | 4 lines

rational.c: optimize rational + rational

* rational.c (f_addsub): optimize rational + rational.
  Author: Tadashi Saito <tad.a.digger@gmail.com>
------------------------------------------------------------------------
r56708 | mrkn | 2016-11-11 23:39:34 +0900 (Fri, 11 Nov 2016) | 4 lines

rational.c: prevent unused warning

* rational.c (f_mod): define only when NDEBUG is not defined to prevent
  unused warning
------------------------------------------------------------------------
r56707 | mrkn | 2016-11-11 23:39:25 +0900 (Fri, 11 Nov 2016) | 8 lines

numeric.c, rational.c: refactor by using FIXNUM_NEGATIVE_P and FIXNUM_ZERO_P

* numeric.c (num_zero_p, fix_divide, fix_mod, fix_divmod): refactor by using
  FIXNUM_NEGATIVE_P and FIXNUM_ZERO_P.

* rational.c (INT_NEGATIVE_P, INT_ZERO_P): ditto.

* internal.h: move FIXNUM_NEGATIVE_P and FIXNUM_ZERO_P from numeric.c
------------------------------------------------------------------------
r56706 | mrkn | 2016-11-11 23:39:16 +0900 (Fri, 11 Nov 2016) | 4 lines

rational.c: optimize Integer#gcd.

* rational.c (f_gcd_normal): optimize Integer#gcd.
  Author: Tadashi Saito <tad.a.digger@gmail.com>
------------------------------------------------------------------------
r56705 | mrkn | 2016-11-11 23:39:07 +0900 (Fri, 11 Nov 2016) | 4 lines

rational.c: optimize rational + integer.

* rational.c (rb_rational_plus): optimize rational + integer.
  Author: Tadashi Saito <tad.a.digger@gmail.com>
------------------------------------------------------------------------
r56704 | mrkn | 2016-11-11 23:38:59 +0900 (Fri, 11 Nov 2016) | 4 lines

rational.c: optimize rational + float.

* rational.c (rb_rational_plus): optimize rational + float.
  Author: Tadashi Saito <tad.a.digger@gmail.com>
------------------------------------------------------------------------
r56703 | nobu | 2016-11-11 20:52:03 +0900 (Fri, 11 Nov 2016) | 4 lines

range.c: check loading

* range.c (range_loader): check loading values if the data came
  from an initialized range object. [ruby-core:78067] [Bug #12915]
------------------------------------------------------------------------
r56702 | nobu | 2016-11-11 16:26:14 +0900 (Fri, 11 Nov 2016) | 4 lines

rational.c: check load

* rational.c (nurat_loader, nurat_marshal_load): check if loading
  values are Integer.  [ruby-core:78071] [Bug #12918]
------------------------------------------------------------------------
r56701 | nobu | 2016-11-11 16:08:53 +0900 (Fri, 11 Nov 2016) | 7 lines

rational.c: optimize

* rational.c (f_{lt,eqeq,zero,one,minus_one,kind_of}_p): add RTEST
  to results of funcalls.

* rational.c (f_negative_p, k_{integer,float,rational}_p):
  optimize.
------------------------------------------------------------------------
r56700 | nobu | 2016-11-11 16:08:52 +0900 (Fri, 11 Nov 2016) | 1 line

rational.c: use RB_INTEGER_TYPE_P
------------------------------------------------------------------------
r56699 | akr | 2016-11-11 12:04:38 +0900 (Fri, 11 Nov 2016) | 2 lines

Enable the document for Kernel[#.]pp.

------------------------------------------------------------------------
r56698 | nobu | 2016-11-11 09:08:41 +0900 (Fri, 11 Nov 2016) | 4 lines

vm_eval.c: reorder

* vm_eval.c (vm_call0_body): reorder the conditions.
  [ruby-core:78073] [Bug #12920]
------------------------------------------------------------------------
r56697 | mrkn | 2016-11-11 00:23:43 +0900 (Fri, 11 Nov 2016) | 3 lines

rational.c: optimize Rational#to_f by using rb_int_fdiv

* rational.c (nurat_to_f): optimize Rational#to_f by using rb_int_fdiv.
------------------------------------------------------------------------
r56696 | svn | 2016-11-11 00:23:34 +0900 (Fri, 11 Nov 2016) | 1 line

* 2016-11-11
------------------------------------------------------------------------
r56695 | mrkn | 2016-11-11 00:23:33 +0900 (Fri, 11 Nov 2016) | 5 lines

numeric.c, internal.h: export int_fdiv() as rb_int_fdiv()

* numeric.c (rb_int_fdiv): export int_fdiv() as rb_int_fdiv().

* internal.h (rb_int_fdiv): add declaration of rb_int_fdiv().
------------------------------------------------------------------------
r56694 | nobu | 2016-11-10 23:18:52 +0900 (Thu, 10 Nov 2016) | 4 lines

vm_eval.c: fix refined method when prepended

* vm_eval.c (vm_call0_body): refined module should not be skipped
  as prepended.  [ruby-core:78073] [Bug #12920]
------------------------------------------------------------------------
r56693 | nobu | 2016-11-10 19:39:51 +0900 (Thu, 10 Nov 2016) | 3 lines

range.c: check if range modifiable

* range.c (range_modify): frozen object cannot be modified.
------------------------------------------------------------------------
r56692 | nobu | 2016-11-10 16:47:44 +0900 (Thu, 10 Nov 2016) | 5 lines

parse.y: new_attr_op_assign in ripper needs symbol

* parse.y (command_asgn, arg): new_attr_op_assign in ripper
  expects a Symbol VALUE as the operator, not an ID, so convert
  literal IDs to Symbols.  [ruby-core:78069] [Bug #12916]
------------------------------------------------------------------------
r56691 | nobu | 2016-11-10 16:47:43 +0900 (Thu, 10 Nov 2016) | 4 lines

test_files.rb: sample size

* test/ripper/test_files.rb (assert_parse_files): extract at least
  one sample.
------------------------------------------------------------------------
r56690 | nobu | 2016-11-10 15:45:57 +0900 (Thu, 10 Nov 2016) | 4 lines

test_files.rb: separate tests

* test/ripper/test_files.rb (assert_parse_files): separate tests
  for each directories.
------------------------------------------------------------------------
r56689 | hsbt | 2016-11-10 15:38:14 +0900 (Thu, 10 Nov 2016) | 4 lines

Use environment variable for system ruby detection on appveyor.

 * Use ruby_version instead of 22-x64 and 21-x64
 * Use 23-x64 to build Ruby
------------------------------------------------------------------------
r56688 | nobu | 2016-11-10 12:50:47 +0900 (Thu, 10 Nov 2016) | 4 lines

make-snapshot: repository options

* tool/make-snapshot: add -svn and -git options to direct the
  repository to export.
------------------------------------------------------------------------
r56687 | nobu | 2016-11-10 12:50:46 +0900 (Thu, 10 Nov 2016) | 4 lines

make-snapshot: program name

* tool/make-snapshot (package): abort with the basename of this
  script.
------------------------------------------------------------------------
r56686 | shugo | 2016-11-10 11:23:58 +0900 (Thu, 10 Nov 2016) | 11 lines

Extend timeout for RubyCI chkbuild on Debian 8.2 x86_64.

On that machine, TestQueue#test_thr_kill often fails as follows:

      1) Failure:
    TestQueue#test_thr_kill [/home/hsbt/chkbuild/tmp/build/20161109T213002Z/ruby/test/thread/test_queue.rb:155]:
    only 171/250 done in 30 seconds.

Even if it passes, it takes about 30 seconds:

    [11160/16832] TestQueue#test_thr_kill = 29.80 s
------------------------------------------------------------------------
r56685 | svn | 2016-11-10 09:49:17 +0900 (Thu, 10 Nov 2016) | 1 line

* 2016-11-10
------------------------------------------------------------------------
r56684 | nobu | 2016-11-10 09:49:17 +0900 (Thu, 10 Nov 2016) | 5 lines

test_process.rb: fix pgroup test

* test/ruby/test_process.rb (TestProcess#test_execopts_pgroup):
  use dynamically assigned pid for the process group, instead of a
  magic number 2.  [ruby-core:78051] [Bug #12909]
------------------------------------------------------------------------
r56683 | nobu | 2016-11-10 09:49:16 +0900 (Thu, 10 Nov 2016) | 3 lines

range.c: indent [ci skip]

* range.c (range_alloc): adjust indent of comments.
------------------------------------------------------------------------
r56682 | nobu | 2016-11-09 11:42:30 +0900 (Wed, 09 Nov 2016) | 4 lines

default.mspec: end of options

* spec/default.mspec (MSpecScript): add the end of options to
  runruby.rb, to fix failure at ruby/spec@a0e55db.
------------------------------------------------------------------------
r56681 | a_matsuda | 2016-11-09 05:25:44 +0900 (Wed, 09 Nov 2016) | 6 lines

Fix undefined method 'dump' for nil:NilClass (NoMethodError)

Patch by: Dmitry Vorotilin <d.vorotilin@gmail.com> (@route)
Signed-off-by: Akira Matsuda <ronnie@dio.jp>

closes #1475
------------------------------------------------------------------------
r56680 | a_matsuda | 2016-11-09 04:55:59 +0900 (Wed, 09 Nov 2016) | 8 lines

Fix grammar errors

Patch by: Chris Tweedie <cltweedie@gmail.com> (@cltweedie)
Signed-off-by: Akira Matsuda <ronnie@dio.jp>

closes #1074

[ci skip]
------------------------------------------------------------------------
r56679 | a_matsuda | 2016-11-09 04:43:58 +0900 (Wed, 09 Nov 2016) | 9 lines

Update documentation of fetch

The sentence `Negative values of +index+ count from the end of the array.` can be interpreted that it only holds if a block is given. Clarify it.

Patch by: Lukas Elmer <lukas.elmer@gmail.com> (@lukaselmer)
Signed-off-by: Akira Matsuda <ronnie@dio.jp>

closes #1472
[ci skip]
------------------------------------------------------------------------
r56678 | a_matsuda | 2016-11-09 04:37:59 +0900 (Wed, 09 Nov 2016) | 15 lines

Fix typo in code doc of proc.c

Insure has a different meaning than ensure and we mean the latter in
this case.

*Ensure* is to do or have what is necessary for success.
Example: These blankets ensure that you?\226?\128?\153ll be warm enough.

*Insure* is to cover with an insurance policy.
Example: I will insure my home with additional fire and flood policies.

Patch by: Dimitris Zorbas <zorbash@skroutz.gr> (@Zorbash)
Signed-off-by: Akira Matsuda <ronnie@dio.jp>

closes #1352
------------------------------------------------------------------------
r56677 | kazu | 2016-11-09 00:04:29 +0900 (Wed, 09 Nov 2016) | 1 line

Add a space [ci skip]
------------------------------------------------------------------------
r56676 | svn | 2016-11-09 00:01:56 +0900 (Wed, 09 Nov 2016) | 1 line

* 2016-11-09
------------------------------------------------------------------------
r56675 | kazu | 2016-11-09 00:01:55 +0900 (Wed, 09 Nov 2016) | 1 line

Add ticket number [ci skip]
------------------------------------------------------------------------
r56674 | a_matsuda | 2016-11-08 20:57:00 +0900 (Tue, 08 Nov 2016) | 6 lines

Update comment about default constant

Patch by: Dave Takahashi <dtcello@gmail.com> (@dtakahas)
Signed-off-by: Akira Matsuda <ronnie@dio.jp>

closes #1151
------------------------------------------------------------------------
r56673 | nobu | 2016-11-08 19:44:21 +0900 (Tue, 08 Nov 2016) | 4 lines

vcs.rb: fix GIT.get_revisions

* tool/vcs.rb (VCS::GIT.get_revisions): fix for out-of-place
  build.
------------------------------------------------------------------------
r56672 | svn | 2016-11-08 18:31:53 +0900 (Tue, 08 Nov 2016) | 1 line

* properties.
------------------------------------------------------------------------
r56671 | naruse | 2016-11-08 18:31:52 +0900 (Tue, 08 Nov 2016) | 3 lines

Moved deleted ChangeLog into doc/ChangeLog-2.4.0

And Add doc/ChangeLog-2016 as an anchor.
------------------------------------------------------------------------
r56670 | nobu | 2016-11-08 16:47:23 +0900 (Tue, 08 Nov 2016) | 5 lines

vcs.rb: format from git-log

* tool/vcs.rb (VCS::GIT#export_changelog): re-format from git-log
  to svn style log, instead of git-svn, because cloned working
  directory would not have .git/svn.
------------------------------------------------------------------------
r56669 | nobu | 2016-11-08 16:45:19 +0900 (Tue, 08 Nov 2016) | 4 lines

vcs.rb: expand srcdir

* tool/vcs.rb (VCS::GIT#initialize): expand srcdir if it is a
  local path.
------------------------------------------------------------------------
r56668 | nobu | 2016-11-08 15:39:46 +0900 (Tue, 08 Nov 2016) | 6 lines

vcs.rb: fix srcdir in VCS::GIT

* tool/vcs.rb (VCS::GIT.cmd_args): add chdir option to arguments
  for IO.popen if srcdir is a local path.  unless -srcdir command
  line option is given, srcdir is the default URL.
  [ruby-core:78036] [Bug #12908]
------------------------------------------------------------------------
r56667 | svn | 2016-11-08 00:26:11 +0900 (Tue, 08 Nov 2016) | 1 line

* 2016-11-08
------------------------------------------------------------------------
r56666 | kazu | 2016-11-08 00:26:10 +0900 (Tue, 08 Nov 2016) | 3 lines

Add entry for Enumerator::Lazy#chunk_while

[ci skip][GH-1186]
------------------------------------------------------------------------
r56665 | kazu | 2016-11-07 21:10:36 +0900 (Mon, 07 Nov 2016) | 1 line

fix a typo [ci skip]
------------------------------------------------------------------------
r56664 | hsbt | 2016-11-07 18:46:42 +0900 (Mon, 07 Nov 2016) | 1 line

Added Entry for Rubygems 2.6.8 update.
------------------------------------------------------------------------
r56663 | nobu | 2016-11-07 16:45:18 +0900 (Mon, 07 Nov 2016) | 4 lines

test_optimization.rb: for r56208

* test/ruby/test_optimization.rb (test_tailcall_condition_block):
  test for r56208.  [ruby-core:78015] [Bug #12905]
------------------------------------------------------------------------
r56662 | shugo | 2016-11-07 15:57:14 +0900 (Mon, 07 Nov 2016) | 1 line

Extend Net::HTTP#open_timeout for chkbuild on Solaris 10s.
------------------------------------------------------------------------
r56660 | naruse | 2016-11-07 14:53:42 +0900 (Mon, 07 Nov 2016) | 1 line

Add NEWS about removing ChangeLog
------------------------------------------------------------------------
r56658 | nobu | 2016-11-07 12:47:46 +0900 (Mon, 07 Nov 2016) | 3 lines

vcs.rb: suppress warning

* tool/vcs.rb (DebugPOpen): suppress refinements warning in 2.0.
------------------------------------------------------------------------
r56657 | nobu | 2016-11-07 12:28:57 +0900 (Mon, 07 Nov 2016) | 3 lines

add cast

* hash.c (rb_objid_hash): need to cast down.
------------------------------------------------------------------------
r56656 | nobu | 2016-11-07 12:25:28 +0900 (Mon, 07 Nov 2016) | 7 lines

vcs.rb: exclude beginning revision

* tool/make-snapshot: pass the last revision in the last ChangeLog
  file without increment.

* tool/vcs.rb (export_changelog): exclude the beginning revision
  of the range uniformly. svn log includes it, but git log not.
------------------------------------------------------------------------
r56655 | nobu | 2016-11-07 11:54:28 +0900 (Mon, 07 Nov 2016) | 6 lines

vcs.rb: unnecessary arguments

* tool/make-snapshot: $srcdir is optional.

* tool/vcs.rb (export_changelog): remove unnecessary arguments.
  VCS should know srcdir and url.
------------------------------------------------------------------------
r56654 | nobu | 2016-11-07 11:54:27 +0900 (Mon, 07 Nov 2016) | 4 lines

vcs.rb: use chdir option

* tool/vcs.rb (export_changelog): for old git, use chdir option
  instead of git -C option, and set language environmets to C.
------------------------------------------------------------------------
r56653 | shugo | 2016-11-07 11:10:00 +0900 (Mon, 07 Nov 2016) | 1 line

Just check that interruption doesn't cause SEGV.
------------------------------------------------------------------------
r56652 | nobu | 2016-11-07 10:23:04 +0900 (Mon, 07 Nov 2016) | 4 lines

make-snapshot: sort globbed results

* tool/make-snapshot (package): globbed results order is
  undefined.
------------------------------------------------------------------------
r56651 | ko1 | 2016-11-07 10:03:04 +0900 (Mon, 07 Nov 2016) | 1 line

fix NEWS message
------------------------------------------------------------------------
r56650 | ko1 | 2016-11-07 09:45:00 +0900 (Mon, 07 Nov 2016) | 19 lines

	Introduce table improvement by Vladimir Makarov <vmakarov@redhat.com>.
	[Feature #12142]
	See header of st.c for improvment details.

	You can see all of code history here:
	<https://github.com/vnmakarov/ruby/tree/hash_tables_with_open_addressing>

	This improvement is discussed at
	<https://bugs.ruby-lang.org/issues/12142>
	with many people, especially with Yura Sokolov.

	* st.c: improve st_table.

	* include/ruby/st.h: ditto.

	* internal.h, numeric.c, hash.c (rb_dbl_long_hash): extract a function.

	* ext/-test-/st/foreach/foreach.c: catch up this change.

------------------------------------------------------------------------
r56649 | nobu | 2016-11-07 09:04:20 +0900 (Mon, 07 Nov 2016) | 3 lines

vcs.rb: popen with env

* tool/vcs.rb (IO.popen): support passing environment variables.
------------------------------------------------------------------------
r56648 | naruse | 2016-11-07 02:34:56 +0900 (Mon, 07 Nov 2016) | 3 lines

revision.h shouldn't depend ChangeLog

Maybe it needs vcs dependent ways.
------------------------------------------------------------------------
