change default not tot create useless object

initheader = initheader ? initheader.dup : {}

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

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46679 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* lib/uri/generic.rb (URI::Generic#query=): remove validation, just
  escape. [Feature #2542]

* lib/uri/generic.rb (URI::Generic#fragment=): ditto.

* lib/uri/generic.rb (URI::Generic#check_query): removed.

* lib/uri/generic.rb (URI::Generic#set_query): ditto.

* lib/uri/generic.rb (URI::Generic#check_fragment): ditto.

* lib/uri/generic.rb (URI::Generic#set_fragment): ditto.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46680 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* lib/net/http/response.rb (Net::HTTP.each_response_header):
  raise first exception even if inflate_body_io.finish raises error.
  when begin block raises error, finish usually raises error too.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46681 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* lib/net/htp/response.rb (Net::Inflater#inflate_adapter):
  prevent automatic encoding conversion.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46682 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Revert "test/rdoc: avoid tempfile leaks"

This reverts commit r46145.

Tempfile.create is only available Ruby 2.1 or higher.
rubygems need to support Ruby 1.9 and 2.0 series.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46683 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test/rubygems/test_gem_package.rb: avoid tempfile leaks using Tempfile#close!
* test/rubygems/test_gem_request_set.rb: ditto.
* test/rubygems/test_gem_request_set_gem_dependency_api.rb: ditto.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46684 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* parse.y: remove unused code
  srounded by `#if ENABLE_SELECTOR_NAMESPACE'



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46685 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
ChangeLog: fix typo  [ci skip]

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

* tool/compile_prelude.rb (translate): remove comments which are
  not used in compiled sources.

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

* parse.y (op_tbl): pack limited size strings.  gcc/clang warn
  if initializer-string for char array is too long, but no option
  to err it now.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46688 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
string.c: rb_fstring_new assumes US-ASCII

* string.c (rb_fstring_new): make US-ASCII string.  another
  function may be used for non-ASCII strings.

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

* parse.y (rb_id2str): use rb_fstring_new() instead of rb_fstring()
  with a new string instance.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46690 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
parse.y: remove global_symbols.op_sym

* parse.y (global_symbols): remove op_sym, cache by fstring
  instead.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46691 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
test/unit.rb: newline after message

* test/lib/test/unit.rb (deal): print a newline after an error
  message for unknown command not to overwritten by next messages.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46692 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* parse.y (must_be_dynamic_symbol): refactoring.
  * add `inline'.
  * use UNLIKELY().
  * check only DYNAMIC_SYM_P(), otherwise it is a bug.
  * lookup_id_str() is not needed in second condition.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46693 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* parse.y (rb_pin_dynamic_symbol): should be `static' function.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46694 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* parse.y (must_be_dynamic_symbol): fix missed-condition.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46695 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* parse.y: rename symbols::sym_id to symbols::str_id.
  This table is not {Symbol => ID} table, but
  {String => ID} table.
* parse.y (lookup_sym_id): also rename lookup_sym_id() to
  lookup_str_id() because key is not Symbol, but String.



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

* parse.y (reg_named_capture_assign_gen): remove needless cast.

* parse.y (must_be_dynamic_symbol, intern_cstr_without_pindown):
  get rid of type-punning cast.

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