debug.rb: Fix debug listing

* lib/debug.rb (display_list): Fix debug listing when called from the
  same file it has been required.  patch by Dario Bertini <berdario AT
  gmail.com> [Bug #8318] [fix GH-280]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40450 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* 2013-04-25

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40451 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
debug.rb: Fix debug listing

* lib/debug.rb (script_lines): get source lines from SCRIPT_LINES__ or
  read from the file.
* lib/debug.rb (display_list): use script_lines instead of recursion.
  [Bug #8318]
* lib/debug.rb (line_at): use script_lines same as display_list.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40452 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
tracer.rb: File.readlines

* lib/tracer.rb (get_line): simply read by File.readlines.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40453 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
configure.in: RUBY_RM_RECURSIVE

* configure.in (RUBY_RM_RECURSIVE): this hack is needed by only
  autoconf 2.69 or earlier on darwin.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40454 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* array.c: Improve rdoc for eql?

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40455 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* ext/socket/extconf.rb: Extract C programs as toplevel constants.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40456 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* benchmark/bm_hash_shift.rb: add benchmark for Hash#shift

* hash.c (rb_hash_shift): use st_shift if hash is not being iterated to
  delete element without iterating the whole hash.

* hash.c (shift_i): remove function

* include/ruby/st.h (st_shift): add st_shift function

* st.c (st_shift): ditto

[Bug #8312] [ruby-core:54524] Patch by funny-falcon

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40457 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* properties.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40458 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* st.c (st_shift): remove unused variable.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40459 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* lib/uri/common.rb (URI.decode_www_form): follow current URL Standard.
  It gets encoding argument to specify the character encoding.
  It now allows loose percent encoded strings, but denies ;-separator.
  [ruby-core:53475] [Bug #8103]

* lib/uri/common.rb (URI.decode_www_form): follow current URL Standard.
  It gets encoding argument to convert before percent encode.
  Now UTF-16 strings aren't converted to UTF-8 before percent encode
  by default.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40460 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* ext/openssl/ossl_bn.c (ossl_bn_initialize): allow Fixnum and Bignum.
  [ruby-core:53986] [Feature #8217]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40461 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
io.c: conversion from bom encoding

* io.c (rb_io_ext_int_to_encs, parse_mode_enc): bom-prefixed name is
  not a real encoding name, just a fallback.  so the proper conversion
  should take place even if if the internal encoding is equal to the
  bom-prefixed name, unless actual encoding is equal to the internal
  encoding.  [ruby-core:54563] [Bug #8323]
* io.c (io_set_encoding_by_bom): reset extenal encoding if no BOM
  found.  [ruby-core:54569]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40462 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
ext/openssl/ossl_bn.c: fix implicit conversion

* ext/openssl/ossl_bn.c (ossl_bn_initialize): fix precision loss by
  implicit conversion.

* ext/openssl/ossl_bn.c (ossl_bn_initialize): check Bignum overflow.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40463 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* ext/socket/extconf.rb: Implement
  --{enable,disable}-close-fds-by-recvmsg-with-peek configure option
  for cross-compiling.
  Make --{enable,disable}-wide-getaddrinfo configure option
  cross-compiling friendly.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40464 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* ext/socket/extconf.rb: Remove obsolete options: ---with-ipv6-lib and
  --with-ipv6-libdir.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40465 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* ext/socket/extconf.rb: Don't use WIDE getaddrinfo by default.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40466 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* ext/curses/extconf.rb: Implement
  --with-curses-version={function,variable} configure option for
  cross-compiling.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40468 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
test_rinda.rb: Use KILL on Windows

* test/rinda/test_rinda.rb (TupleSpaceProxyTest#test_take_bug_8215):
  use KILL on Windows since TERM doen't work and ruby process remains
  after test-all on Windows.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40469 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
ring.rb: add a socket to @sockets in make_socket()

* lib/rinda/ring.rb (Rinda::RingServer#initialize): add a socket
  to @sockets in make_socket() to close sockets on shutdown even if
  make_socket() is called after initialize.

* lib/rinda/ring.rb (Rinda::RingServer#make_socket): ditto.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40470 b2dd03c8-39d4-4d8f-98ff-823fe69b080e