aboutsummaryrefslogtreecommitdiffstats
path: root/NEWS
Commit message (Collapse)AuthorAgeFilesLines
* NEWS: note IO#wait_readable change in r50263normal2015-04-151-0/+4
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@50327 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* connect_nonblock supports "exception: false"normal2015-04-121-4/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is for consistency with accept_nonblock arguments and gives a minor speedup from avoiding exceptions. [ruby-core:68838] [Feature #11024] * ext/openssl/ossl_ssl.c (ossl_ssl_connect_nonblock): support `exception: false' * (get_no_exception): move function location * ext/socket/socket.c (sock_connect_nonblock): support `exception: false' * test/openssl/test_pair.rb (test_connect_accept_nonblock_no_exception): test `exception: false' on connect, rename from `test_accept_nonblock_no_exception' * test/socket/test_nonblock.rb (test_connect_nonblock_no_exception): new test Benchmark results: default 0.050000 0.100000 0.150000 ( 0.151307) exception: false 0.030000 0.080000 0.110000 ( 0.108840) ----------------------------8<----------------------- require 'socket' require 'benchmark' require 'io/wait' require 'tmpdir' host = '127.0.0.1' serv = TCPServer.new(host, 0) # UNIX sockets may not hit EINPROGRESS nr = 5000 # few iterations to avoid running out of ports addr = serv.getsockname pid = fork do begin serv.accept.close rescue => e warn "#$$: #{e.message} (#{e.class})" end while true end at_exit { Process.kill(:TERM, pid) } serv.close Benchmark.bmbm do |x| x.report("default") do nr.times do s = Socket.new(:INET, :STREAM) s.setsockopt(:SOL_SOCKET, :SO_REUSEADDR, 1) begin s.connect_nonblock(addr) rescue IO::WaitWritable s.wait_writable end s.close end end x.report("exception: false") do nr.times do s = Socket.new(:INET, :STREAM) s.setsockopt(:SOL_SOCKET, :SO_REUSEADDR, 1) case s.connect_nonblock(addr, exception: false) when :wait_writable s.wait_writable end s.close end end end git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@50254 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/objspace/objspace.c: add ObjectSpace.count_imemo_objects methodko12015-04-101-0/+3
| | | | | | | | | | to count imemo objects for each type. * test/objspace/test_objspace.rb: add a test. * NEWS: describe about this addition. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@50211 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * enum.c: Enumerable#chunk and Enumerable#slice_before no longer takesakr2015-04-061-0/+5
| | | | | | | | the initial_state argument. [Feature #10958] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@50174 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* accept_nonblock supports "exception: false"normal2015-03-121-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is analogous to functionality found in IO#read_nonblock and IO#wait_nonblock. Raising exceptions for common failures on non-blocking servers is expensive and makes $DEBUG too noisy. Benchmark results: user system total real default 2.790000 0.870000 3.660000 ( 3.671597) exception: false 1.120000 0.800000 1.920000 ( 1.922032) exception: false (cached arg) 0.820000 0.770000 1.590000 ( 1.589267) --------------------- benchmark script ------------------------ require 'socket' require 'benchmark' require 'tmpdir' nr = 1000000 Dir.mktmpdir('nb_bench') do |path| sock_path = "#{path}/test.sock" s = UNIXServer.new(sock_path) Benchmark.bmbm do |x| x.report("default") do nr.times do begin s.accept_nonblock rescue IO::WaitReadable end end end x.report("exception: false") do nr.times do begin s.accept_nonblock(exception: false) rescue IO::WaitReadable abort "should not raise" end end end x.report("exception: false (cached arg)") do arg = { exception: false } nr.times do begin s.accept_nonblock(arg) rescue IO::WaitReadable abort "should not raise" end end end end end * ext/socket/init.c (rsock_s_accept_nonblock): support exception: false [ruby-core:66385] [Feature #10532] * ext/socket/init.c (rsock_init_socket_init): define new symbols * ext/socket/rubysocket.h: adjust prototype * ext/socket/socket.c (sock_accept_nonblock): support exception: false * ext/openssl/ossl_ssl.c (ossl_ssl_accept_nonblock): ditto * ext/socket/socket.c (Init_socket): adjust accept_nonblock definition * ext/openssl/ossl_ssl.c (Init_ossl_ssl): ditto * ext/socket/tcpserver.c (rsock_init_tcpserver): ditto * ext/socket/unixserver.c (rsock_init_unixserver): ditto * ext/socket/tcpserver.c (tcp_accept_nonblock): adjust rsock_s_accept_nonblock call * ext/socket/unixserver.c (unix_accept_nonblock): ditto * ext/openssl/ossl_ssl.c (ossl_start_ssl): support no_exception * ext/openssl/ossl_ssl.c (ossl_ssl_connect): adjust ossl_start_ssl call * ext/openssl/ossl_ssl.c (ossl_ssl_connect_nonblock): ditto * ext/openssl/ossl_ssl.c (ossl_ssl_accept): ditto * test/socket/test_nonblock.rb (test_accept_nonblock): test for "exception :false" * test/socket/test_tcp.rb (test_accept_nonblock): new test * test/socket/test_unix.rb (test_accept_nonblock): ditto * test/openssl/test_pair.rb (test_accept_nonblock_no_exception): ditto git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@49948 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/matrix.rb: Add Vector#round. Patch by Jordan Stephens.marcandre2015-03-051-0/+3
| | | | | | [Fixes GH-802] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@49866 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/coverage/coverage.c: Add Coverage.peek_result. Allows you totenderlove2015-02-131-0/+4
| | | | | | | | | capture coverage information without stopping the coverage tool. [ruby-core:67940] [Feature #10816] * test/coverage/test_coverage.rb: test for change. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@49589 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/base64.rb: make urlsafe mode user-friendly.mame2015-02-131-0/+6
| | | | | | | | | | | | | * lib/base64.rb (Base64.urlsafe_encode64): a new option "padding" to suppress the padding character ("="). * lib/base64.rb (Base64.urlsafe_decode64): now it accepts not only correctly-padded input but also unpadded input. [Feature #10740][ruby-core:67570] * test/base64/test_base64.rb: Test for above git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@49585 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* array.c: reduce to_ary callnobu2015-01-251-0/+3
| | | | | | | * array.c (flatten): no need to call to_ary method on elements beyond the given level. [ruby-core:67637] [Bug #10748] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@49400 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* #10714 is a feature.akr2015-01-211-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@49361 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * NEWS: References to tickets added.akr2015-01-211-2/+2
| | | | | | | [ruby-core:67701] [Bug #10760] Suggested by Zachary Scott. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@49360 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Describe IO#close.akr2015-01-151-0/+3
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@49263 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* array.c: linear performancenobu2015-01-151-0/+5
| | | | | | | * array.c (rb_ary_select_bang, ary_reject_bang): linear performance. [ruby-core:67418] [Feature #10714] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@49255 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/drb/drb.rb: removed unused argument. Patch by @vipulnswardhsbt2015-01-041-0/+3
| | | | | | [fix GH-515] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@49130 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * NEWS: added compatibility entry of r49101.hsbt2015-01-031-0/+3
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@49109 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* old ChangeLog and NEWS move to dockazu2014-12-251-328/+2
| | | | | | | | | * doc/NEWS-2.2.0: moved from NEWS * doc/ChangeLog-2.2.0: moved ChangeLog older than created ruby_2_2 branch * NEWS: NEWS for 2.3.0 that describes changes since 2.2.0 * ChangeLog: ChangeLog since branch point of ruby_2_2 branch git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@49008 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* fix a typo [ci skip]kazu2014-12-171-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48879 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * NEWS: mention about IO#fsync (and IO#flush). adviced by kosaki.usa2014-12-161-3/+4
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48866 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/objspace/objspace.c: ObjectSpace.memsize_of(obj) returnsko12014-12-151-0/+4
| | | | | | | | | | | | with sizeof(RVALUE). [Bug #8984] * gc.c (obj_memsize_of): ditto. * NEWS: add a NEWS entry. * test/objspace/test_objspace.rb: catch up this fix. * test/ruby/test_file_exhaustive.rb: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48846 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * gc.c (gc_latest_gc_info): return :state field to show currentko12014-12-121-0/+1
| | | | | | | | | GC state (none/marking/sweeping). [Feature #10590] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48783 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * NEWS: add obsolete callcc.kazu2014-11-271-0/+3
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48611 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * gc.c (objspace_malloc_increase): enable lazy sweep on GC by malloc()ko12014-11-271-0/+1
| | | | | | | | | | (malloc_increase) to make GC incrementally. This change can increase memory consumption. Report us if you find any problem. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48603 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Describe about TSort.each_*akr2014-11-271-0/+5
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48601 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* ruby.h: export keyword argument functionsnobu2014-11-261-0/+3
| | | | | | | * include/ruby/ruby.h (rb_get_kwargs, rb_extract_keywords): export keyword argument functions. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48590 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Move the description about vfork.akr2014-11-251-2/+4
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48565 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * NEWS: add an "Implementation changes" section.ko12014-11-251-0/+13
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48564 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/rake: Update to rake 10.4.0drbrain2014-11-251-0/+5
| | | | | | | | | | | * test/rake: ditto. * NEWS: ditto. * test/lib/minitest/unit.rb: Add compatibility shim for minitest 5. This only provides minitest 5 unit test naming compatibility. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48560 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/matrix.rb: Vector#independent? and associated class methodmarcandre2014-11-191-0/+1
| | | | | | patch by gogo tanaka [#10451] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48506 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/matrix.rb: Add Vector#angle_withmarcandre2014-11-191-0/+1
| | | | | | Patch by Egunov Dmitriy [#10442] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48505 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* vm_eval.c: UncaughtThrowErrornobu2014-11-151-0/+3
| | | | | | | * vm_eval.c (rb_throw_obj): throw UncaughtThrowError instead of ArgumentError. [Feature #10480] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48433 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * NEWS: mention about IO#nonblock_{read,write} of Windows' pipe.usa2014-11-141-0/+4
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48421 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* fix a typo [ci skip]kazu2014-11-061-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48294 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* string.c: no terminatornobu2014-11-051-4/+4
| | | | | | | | * string.c (rb_str_{,l,r}strip_bang): rb_str_subseq() will not NUL-terminate the result string, in the future, so it will not be needed in other cases. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48280 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * NEWS: added period into Matrix section. [ci skip]hsbt2014-11-031-4/+4
| | | | | | [misc #10446][ruby-core:65987] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48246 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/dl/*: remove DL as it is replaced by Fiddle.tenderlove2014-10-311-0/+3
| | | | | | | | | [Feature #5458] Thanks to Jonan Scheffler <jonanscheffler@gmail.com> for this patch * test/dl/*: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48217 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Make Digest() thread-safe.knu2014-10-311-0/+5
| | | | | | | | | | | * ext/digest/lib/digest.rb (Digest()): This function should now be thread-safe. If you have a problem with regard to on-demand loading under a multi-threaded environment, preload "digest/*" modules on boot or use this method instead of directly referencing Digest::*. [Bug #9494] cf. https://github.com/aws/aws-sdk-ruby/issues/525 git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48213 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/matrix.rb: Generalize Vector#cross_product to arbitrary dimensionsmarcandre2014-10-291-0/+1
| | | | | | based on a patch by gogo tanaka [#10074] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48183 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/matrix.rb: Add Matrix#adjucatemarcandre2014-10-291-0/+1
| | | | | | patch by gogo tanaka [#10056] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48182 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/matrix.rb: Add aliases for Vector#cross & dotmarcandre2014-10-291-0/+1
| | | | | | patch by gogo tanaka [#10352] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48181 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* hash.c: rb_hash_delete does not call the blocknobu2014-10-231-0/+2
| | | | | | | * hash.c (rb_hash_delete): now does not call the block given to the current method. [ruby-core:65861] [Bug #10413] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48114 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* NEWS: Added String#unicode_normalize(|!|d?) [ci skip]duerst2014-10-231-0/+6
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48103 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/xmlrpc/parser.rb: added new parser class using libxml-ruby gem.hsbt2014-10-131-0/+3
| | | | | | | [Feature #9379][ruby-core:59633] * lib/xmlrpc/config.rb: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47902 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* ruby/io.h: deprecate old macrosnobu2014-10-101-0/+2
| | | | | | | * include/ruby/io.h (rb_io_mode_flags, rb_io_modenum_flags): deprecate old macros for compatibility for ruby 1.8 and older. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47861 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/matrix.rb: Add @- and @+ for Matrix and Vector.marcandre2014-10-071-0/+1
| | | | | | patch by gogo tanaka [#10068] [#10069] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47840 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * NEWS: Move Matrix changes to the right placemarcandre2014-10-071-12/+12
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47839 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/matrix.rb: Add Matrix#laplace_expansion.marcandre2014-10-071-0/+2
| | | | | | patch by gogo tanaka [#10073] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47835 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/matrix.rb: Add Vector.basis.marcandre2014-10-071-0/+1
| | | | | | Based on patch by gogo tanaka [#10072] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47833 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* NEWS: mentioned about [Bug #9593]nobu2014-10-031-0/+4
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47776 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * lib/matrix.rb: Add hstack & vstack methods.marcandre2014-10-031-0/+2
| | | | | | Based on a patch by creasywuqiong. [Fix GH-344] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47769 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Describe Etc.nprocessors.akr2014-10-021-0/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47762 b2dd03c8-39d4-4d8f-98ff-823fe69b080e