Граф коммитов

25092 Коммитов

Автор SHA1 Сообщение Дата
ngoto ca1c23e2a7 * test/ruby/envutil.rb (assert_no_memory_leak): On Solaris 9 or later,
if possible, execute child ruby with environment variables
  LD_PRELOAD=libumem.so UMEM_OPTIONS="backend=mmap". With these
  variables, freed memory is immediately returned to the OS.
  [Bug #10020] [ruby-dev:48391]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46791 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-11 16:32:07 +00:00
kazu f063a0b535 fix plural form [ci skip]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46788 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-11 13:58:02 +00:00
suke 610877045a * ext/win32ole/win32ole.c: add WIN32OLE_RECORD class to support
VT_RECORD OLE variables.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46785 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-11 11:50:51 +00:00
hsbt 28cdf9b1d1 * lib/abbrev.rb: remove executable.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46784 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-11 08:16:05 +00:00
hsbt c2eac0e78c * lib/fileutils.rb: handle ENOENT error with symlink targeted to
non-exists file. [ruby-dev:45933] [Bug #6716]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46783 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-11 07:51:19 +00:00
hsbt 94bbd10ea7 * array.c: Clarify documentation for Array#insert.
[ruby-core:62934] [Bug #9901]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46782 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-11 07:00:49 +00:00
hsbt dcf296f74c * io.c: Improve Documentation by @dapplebeforedawn.
[fix GH-658] [ruby-core:63579] [Bug #10012]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46781 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-11 06:41:44 +00:00
marcandre 72d0536606 * lib/matrix.rb: Fix sign for cross_product [#9499]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46780 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-11 05:19:33 +00:00
ko1 9412551ee2 * benchmark/prepare_so_k_nucleotide.rb: use require_relative.
* benchmark/prepare_so_reverse_complement.rb: ditto.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46779 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-11 02:13:09 +00:00
nobu 8a608d2b1f pack.c: fix buffer overrun
* pack.c (encodes): fix buffer overrun by tail_lf.  Thanks to
  Mamoru Tasaka and Tomas Hoger.  [ruby-core:63604] [Bug #10019]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46778 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-11 01:09:05 +00:00
ngoto 90b1b2e607 * hash.c (ruby_setenv): Fix TestEnv#test_aset failure on Solaris 9.
When name contains '=', ruby_setenv raises Errno::EINVAL.
  That is the same behavior as Solaris 10.
  NULL check for malloc return value is also added.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46776 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-10 15:22:07 +00:00
nobu 813ad48975 vm_insnhelper.c: fix implicit splat keyword argument
* vm_insnhelper.c (vm_callee_setup_keyword_arg): adjust VM stack
  pointer to get rid of overwriting splat arguments by arguments
  for `to_hash` conversion.  [ruby-core:63593] [Bug #10016]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46775 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-10 06:02:54 +00:00
kazu 01bced94a9 fix typos [ci skip]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46774 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-10 04:17:52 +00:00
ko1 96815f1ebe * symbol.c: remove rb_gc_mark_symbols().
fstrings refered by static symbols and pinned dynamic symbols
  are registerd by rb_gc_register_mark_object().
  frstring refered by dynamic symbols (not pinned symbols)
  are refered from global_symbols.dsymbol_fstr_hash (Hash object).
  Note that fstrings refered from dynamic symbols must live loger
  than symbol objects themselves because rb_gc_free_dsymbol() uses
  fstring to remove from symbol tables.
  This is why we can not mark fstrings from dynamic symbols.
  This technique reduces root objects for GC marking.
* gc.c (gc_mark_roots): ditto.
* internal.h: ditto.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46772 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-09 16:19:13 +00:00
ngoto 60ee5e03f1 * common.mk (DTRACE_DEPENDENT_OBJS): fix build failure on Solaris
introduced in r46768. Object files containing dtrace probes should
  be listed in DTRACE_DEPENDENT_OBJS.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46770 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-09 15:28:53 +00:00
nobu 94ce481263 symbol.c, symbol.h: split from parse.y
* symbol.c, symbol.h: Symbol class implementation and internals,
  split from parse.y.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46768 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-09 08:07:32 +00:00
ko1 76a929a7fc * parse.y: change Symbol <-> ID relationship to avoid
exposing IDs from collectable symbols.
  [Bug #10014]
  Now, rb_check_id() returns 0 if corresponding symbol is
  pinned dynamic symbol.
  There is remaining intern_cstr_without_pindown(), it can return
  IDs from collectable symbols. We must be careful to use it
  (only used in parse.y).  I think it should be removed if
  it does not have impact for performance.
* parse.y:
  add:
  * STATIC_SYM2ID()
  * STATIC_ID2SYM()
  rename:
  * rb_pin_dynamic_symbol() -> dsymbol_pindown()
* internal.h:
  remove:
  * rb_check_id_without_pindown()
  * rb_sym2id_without_pindown()
  add:
  * rb_check_symbol()
  * rb_check_symbol_cstr()
* load.c: use rb_check_id() or rb_check_id_cstr().
* object.c: ditto.
* struct.c: ditto.
* thread.c: ditto.
* vm_method.c: ditto.
* string.c (sym_find): use only rb_check_symbol().
* sprintf.c (rb_str_format): use rb_check_symbol_cstr().



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46764 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-09 06:14:41 +00:00
ko1 37f018fdf5 * parse.y (symbols_i): delete garbage symbols for Symbol.all_symbols.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46763 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-09 05:00:53 +00:00
normal b10058ae36 thread_pthread.h: do not expose pthread type for lock
* thread_pthread.h (struct rb_global_vm_lock_struct):
  do not expose pthread type for lock

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46761 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-08 20:50:37 +00:00
normal 3e14cdc45b thread_pthread.h: remove unneeded semaphore.h include
* thread_pthread.h: remove unneeded semaphore.h include
  We currently do not use POSIX semaphores.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46760 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-08 20:47:58 +00:00
keiju 44ab0f8b3a * lib/irb/ruby-lex.rb: fix counting indent in identify_string_dvar.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46758 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-08 15:19:30 +00:00
kazu aae3bcbc25 fix a typo [ci skip]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46757 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-08 13:14:01 +00:00
nobu 286eaeb24f memory_status.rb: find proper ps
* test/ruby/memory_status.rb (Memory::PSCMD): use ps command which
  outputs expected result.  [ruby-dev:48370] [Bug #10010]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46755 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-08 07:58:03 +00:00
ko1 fd7073f7aa * parse.y (dsymbol_alloc): set global_symbols.minor_marked to 0.
* parse.y (dsymbol_check): set RSYMBOL(sym)->fstr to 0
  because we should not touch fstr after that.
* parse.y (rb_gc_free_dsymbol): skip deleting str and sym
  from tables if fstr == 0.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46752 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-08 05:48:36 +00:00
ko1 8572ed5c0d * parse.y: remove global_symbols::pinned_dsym
(and ::pinned_dsym_minor_marked).
  Mark pinned dsymbols by rb_gc_register_mark_object() because
  they are immortal.
* prase.y (rb_gc_free_dsymbol): rename parameter name `ptr' to `sym'.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46749 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-07 05:36:25 +00:00
ko1 2e225e2c8b * gc.c: revert miss-commit.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46740 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-07 03:46:15 +00:00
ko1 2c551e4715 * parse.y: need to use updated (re-created) symbols.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46737 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-07 03:42:42 +00:00
naruse 011b74b748 * tool/mkconfig.rb: remove not to require rbconfig/obsolete.rb.
* lib/rbconfig/obsolete.rb: removed.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46730 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-07 02:07:01 +00:00
ko1 a31219c91c * parse.y: do not use rb_gc_resurrect(), but create a new dynamic
symbol for garbage dynamic symbol.
* common.mk: use gc.h by parse.y.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46729 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-07 01:53:54 +00:00
ko1 7ad35210a3 * string.c (fstr_update_callback): do not use rb_gc_resurrect()
any more.
  Make new frozen string and replace with garbage frozen string.
* common.mk: use gc.h from string.c.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46727 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-06 17:20:30 +00:00
ko1 2006bfe2f4 * gc.c: rename is_dying_object() to is_garbage_object().
* gc.h: rb_objspace_garbage_object_p() as an exported function.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46726 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-06 15:42:14 +00:00
ko1 094949cb0a * gc.c (is_dying_object): fix missed condition.
* gc.c (is_live_object): move frequent path first.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46717 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-06 12:33:12 +00:00
ko1 38943e80d6 * gc.c: rename is_dead_object() to is_dying_object().
This function is not opposite against is_live_object()
  because is_dying_object() does *not* check object type.
* gc.c (is_dying_object): change condition.
* gc.c (is_live_object): use T_NONE instead of 0.
* gc.c (rb_objspace_dying_object_p): added.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46716 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-06 12:02:57 +00:00
ko1 a617afc643 * gc.c (rb_gc_register_mark_object): change data structure.
From single array, to array of arrays. Each array only has 1024
  entries.
* vm.c (Init_vm_objects): change default capa from 1 to 128.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46714 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-06 04:42:35 +00:00
kazu 566f1e7184 fix a typo [ci skip]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46701 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-05 02:54:26 +00:00
nobu c2356225c4 lib/irb/locale.rb: fix typo
* lib/irb/locale.rb (IRB::Locale#modifier): fix wrong attr_reader
  `modifieer` => `modifier` from irb locale.  [fix GH-656]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46700 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-04 20:05:54 +00:00
ko1 336f65eb57 * 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
2014-07-04 11:48:47 +00:00
ko1 a99a88d49d * 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
2014-07-04 09:42:55 +00:00
ko1 cc462eed98 * 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
2014-07-04 09:39:14 +00:00
ko1 a227b16eba * 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
2014-07-04 09:11:05 +00:00
nobu c46bafcbfd ChangeLog: fix typo [ci skip]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46686 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-04 04:03:28 +00:00
ko1 3e8a898bfe * 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
2014-07-04 02:56:34 +00:00
hsbt ae15655030 * 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
2014-07-04 01:09:27 +00:00
naruse d8a2c3c03f * 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
2014-07-03 19:46:44 +00:00
naruse 6811973d13 * 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
2014-07-03 19:46:34 +00:00
naruse 7af7388202 * 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
2014-07-03 18:00:08 +00:00
kazu 4c81c909b8 fix a part of speech [ci skip]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46668 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-03 04:38:44 +00:00
nobu c2b0992156 configure.in: fix static-linked-ext
* configure.in (--with-static-linked-ext): fix for extensions to
  be linked statically.
* Makefile.in, common.mk: use ENCSTATIC for enc directory.
* ext/extmk.rb: supply dependencies of statically linked extension
  libraries.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46666 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-03 03:40:24 +00:00
ko1 41fe524857 * gc.c (gc_heap_lazy_sweep): simplify logic.
* gc.c (gc_page_sweep): return TRUE if empty slots are available.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46653 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-02 06:47:10 +00:00
hsbt 931d2fd5d8 * logger.rb: removed unmaintain code.
[Feature #9860][ruby-core:62724]
* test/logger/test_application.rb: ditto.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46650 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-02 01:41:02 +00:00
charliesome d3a54f6fe8 Fix --dump=parsetree segfault on required keyword argument
* node.c (dump_node): handle nd_value == (NODE *)-1 to mean this
  keyword argument is required

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46649 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-01 18:21:22 +00:00
nobu 1a2b90d5e6 vm.c: rb_vm_env_local_variables
* vm.c (rb_vm_env_local_variables): returns array of local
  variable name symbols in the environment by envval.
* proc.c (bind_local_variables): use rb_vm_env_local_variables.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46648 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-01 17:57:37 +00:00
nobu 43ba2c01e7 proc.c: Binding#receiver
* proc.c (bind_receiver): new method to return the bound receiver
  of the binding object.  [ruby-dev:47613] [Feature #8779]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46646 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-01 17:24:02 +00:00
nobu 02c391a1c9 proc.c: fix infinite loop
* proc.c (bind_local_variables): update env from envval for each
  iterations.  [ruby-dev:48351] [Bug #10001]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46645 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-01 17:14:48 +00:00
usa 061e4c3f7a * NEWS: [DOC] mention about Binding#local_variables, introduced at
r44392 (see [Feature #8773]).


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46639 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-01 14:51:13 +00:00
nagachika 71336a03fa * numeric.c (num_step_scan_args): table argument of rb_get_kwargs() is
array of IDs, not Symbols. [ruby-dev:48353] [Bug #9811]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46638 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-01 14:36:03 +00:00
knu e2e4ac3a8f Digest::HMAC is finally removed as previously noticed. [fix GH-648]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46635 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-01 07:21:08 +00:00
hsbt f8a38a36eb * ext/date/lib/date/format.rb: removed empty file by @vipulnsward.
* ext/date/lib/date.rb: removed needless require.
  [fix GH-647]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46633 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-07-01 02:28:56 +00:00
ko1 51ae29a3cb * gc.c (gc_stat_internal): return size_t value instead of VALUE
and remove `out' parameter.
* gc.c: add braces for `if' statements.
* gc.c (gc_stat_internal): fix comment.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46623 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-30 07:46:57 +00:00
ko1 4369806ff0 * gc.c: support `USE_RGENGC == 0'.
* test/ruby/test_gc.rb: ditto.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46622 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-30 06:14:37 +00:00
hsbt b5a000bf4c * file.c: [DOC] document File.join returns a string.
Contributed by @dapplebeforedawn. [fix GH-646]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46620 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-30 02:37:31 +00:00
usa d0465cc9e0 * ext/pathname/pathname.c (path_birthtime): Windows support.
see [Feature #9857] [ruby-dev:48339]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46604 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-28 13:58:01 +00:00
akr b9faaf6a55 * ext/pathname/pathname.c (path_birthtime): New method,
Pathname#birthtime.
  Proposed by Kazuhiro NISHIYAMA.  [ruby-dev:48232] [Feature #9857]



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46602 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-28 13:46:02 +00:00
nobu 38f013391d bigdecimal/math.rb: error message in BigMath#PI
* ext/bigdecimal/lib/bigdecimal/math.rb (BigMath#PI): change error
  message about zero or negative precision for clarity and
  consistency with other methods.  [GH-644]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46600 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-28 11:29:11 +00:00
akr 8b76d21f55 * lib/webrick/utils.rb (create_listeners): Close socket objects.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46598 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-28 06:33:44 +00:00
nobu fd4df3be5c eval.c: no overwrite SystemStackError backtrace
* eval.c (setup_exception): should not overwrite SystemStackError
  backtrace if set already.  [ruby-core:63377] [Feature #6216]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46594 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-28 04:58:53 +00:00
nobu 3ff85b795a eval.c: no method calls at stack overflow
* eval.c (setup_exception): get rid of method calls before raising
  stack overflow, not to cause stack overflow again.
* defs/id.def: add IDs for backtraces.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46593 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-28 04:58:25 +00:00
naruse e63ab5d3ad * lib/uri/mailto.rb: update to latest specs, RFC 6068 and HTML5.
* lib/uri/mailto.rb (HEADER_PATTERN): removed.

* lib/uri/mailto.rb (HEADER_REGEXP): use RFC 6068 hfields.

* lib/uri/mailto.rb (EMAIL_REGEXP): use HTML5 email regexp.

* lib/uri/mailto.rb (URI::MailTo.build): support multiple to addresses.

* lib/uri/mailto.rb (URI::MailTo#initialize): Support multiple to
  addresses. Don't check with regexp, only split.

* lib/uri/mailto.rb (URI::MailTo#check_to): verify by matching
  URI path-rootless and HTML5 email regexp with unescaped one.

* lib/uri/mailto.rb (URI::MailTo#check_headers): verify only by
  HEADER_REGEXP.

* lib/uri/mailto.rb (URI::MailTo#set_headers): don't check by
  HEADER_REGEXP, only split it.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46590 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-27 19:26:43 +00:00
nobu bffd6395d6 mkconfig.rb: fix empty prefix
* tool/mkconfig.rb: fix empty RbConfig::CONFIG["prefix"] when
  configured --with-rubyarchprefix, remove prefix from rubyarchdir
  after expansion for the case it does not start with '$(prefix)'.
  [fix GH-643]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46586 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-27 15:35:15 +00:00
hsbt cc02a4ab7b * lib/rubygems/test_case.rb: rescue Gem::LoadError in Gem::TestCase.
because it's effected by removing minitest from stdlib.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46574 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-27 06:32:59 +00:00
hsbt b0bc563550 * lib/rubygems/specification.rb: fixed broken condition caused
by removing YAML::ENGINE.
* lib/rubygems/package/old.rb: ditto.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46571 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-27 03:35:51 +00:00
nobu 68bc5ba1b6 hash.c: fix memory leak
* hash.c (env_shift): fix memory leak on Windows, free environment
  strings block always.  [ruby-dev:48332] [Bug #9983]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46570 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-26 20:33:34 +00:00
nobu cfa7b2283b sprintf.c: unnumbered asterisk with numbered argument
* sprintf.c (GETASTER): should not use the numbered argument to be
  formatted, raise ArgumentError instead.
  [ruby-dev:48330] [Bug #9982]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46569 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-26 18:41:57 +00:00
kazu 29fc4912fb fix a typo [ci skip]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46565 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-26 13:35:46 +00:00
hsbt 767358108e * test/with_different_ofs.rb: move into test library directory.
* test/csv/base.rb: fix require path for with_different_ofs.rb.
* test/digest/test_digest_extend.rb: ditto.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46563 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-26 09:27:22 +00:00
hsbt 4af87bd672 * test/profile_test_all.rb: move into test library directory.
* test/runner.rb: fix require path for profile_test_all.rb.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46562 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-26 09:16:56 +00:00
usa 5e63196957 * ChangeLog: typo.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46561 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-26 09:14:45 +00:00
hsbt c9134128cb * lib/webrick/httpproxy.rb: remvoe useless assigned variables.
* lib/webrick/httpservlet/cgihandler.rb: ditto.
* lib/webrick/httpservlet/erbhandler.rb: ditto.
* lib/webrick/server.rb: ditto.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46560 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-26 09:05:58 +00:00
hsbt 46724873b0 Revert "Revert "* lib/yaml.rb: Remove Psych::EngineManager [Bug #8344]""
syck-1.0.3 gem support this imcompatible changes.

This reverts commit r46102

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46559 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-26 02:52:46 +00:00
nobu 78c763a25c hash.c: fix memory leak
* hash.c (env_select): fix memory leak and crash on Windows, make
  keys array first instead of iterating on envrion directly.
  [ruby-dev:48325] [Bug #9978]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46557 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-25 23:28:04 +00:00
nobu f96f013955 eval_error.c: newline always
* eval_error.c (error_print): put a newline after an anonymous
  exception class name.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46551 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-25 17:45:10 +00:00
nobu 4198f1473a hash.c: fix memory leak
* hash.c (ruby_setenv): fix memory leak on Windows, free
  environment strings block after check for the size.
  [ruby-dev:48323] [Bug #9977]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46550 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-25 13:31:34 +00:00
normal 57c9c3189a ccan/container_of/container_of.h: avoid warning with -Wcast-qual
* ccan/container_of/container_of.h (container_off_var):
  avoid warning with -Wcast-qual
  [ccan ba5ad771af4aa9e085498de6c3c665c52694460f (Rusty Russell)]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46548 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-25 06:55:10 +00:00
nobu 51a1c68bc7 hash.c: prohibit tainted strings
* hash.c (env_aset, env_has_key, env_assoc, env_has_value),
  (env_rassoc, env_key): prohibit tainted strings if $SAFE is
  non-zero.  [Bug #9976]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46547 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-25 01:20:01 +00:00
hsbt 4f7449beba * lib/gserver.rb: remove redundant use of to_s in interpolation.
* lib/logger.rb: ditto.
* lib/optparse.rb: ditto.
* lib/rbconfig/obsolete.rb: ditto.
* lib/resolv.rb: ditto.
* lib/webrick/httpresponse.rb: ditto.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46543 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-24 08:48:46 +00:00
naruse a054854324 Revert "* lib/uri/mailto.rb: support RFC6068."
to fix mailto URI syntax

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46541 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-24 02:58:45 +00:00
kazu bc7919a9cd fix a typo [ci skip]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46539 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-24 02:07:08 +00:00
nobu 5c9bc9f8e1 hash.c: frozen PATH env
* hash.c (env_path_str_new): make PATH environment variable
  string, to be frozen.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46538 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-24 01:50:09 +00:00
hsbt 27d345dff4 * tool/make-snapshot: download bundle gems when package making.
[Feature #9852][ruby-core:62676]
* gems/bundled_gems: listed bundled gems for Ruby 2.2.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46536 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-24 01:45:41 +00:00
hsbt 204a83f5f3 * tool/downloader.rb: make Downloader class to general download utility.
It can be used without config.guess and configu.sub.
* tool/get-config_files: ditto.
* tool/make-snapshot: ditto.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46535 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-24 01:26:21 +00:00
naruse e5e37ecfc2 * eval.c (setup_exception): "mesg == sysstack_error" and
sysstack_error_p(mesg) are duplicated.
  r46502 seems to want to use latter.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46531 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-23 21:21:00 +00:00
nobu e3e359ba79 tcltklib.c: fix format specifiers
* ext/tk/tcltklib.c: fix format specifiers for VALUE and
  Tcl_Interp*.  [ruby-core:63283] [Bug #9972]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46530 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-23 21:15:39 +00:00
kosaki 476af221b7 * nacl/nacl-config.rb: Use File.exist? instead of executable?
for irt_core. Recent nacl_sdk has non-executable irt_core.
  Patch by Shinichiro Hamaji.
  [Fixes GH-529] https://github.com/ruby/ruby/pull/529

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46529 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-23 20:53:16 +00:00
naruse a672789739 * lib/uri/mailto.rb: support RFC6068.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46528 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-23 20:01:27 +00:00
hsbt 7a05e0ae9f * tool/config_files.rb: rename class ConfigFiles to Downloader.
* tool/get-config_files: ditto.
* tool/make-snapshot: ditto.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46517 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-23 09:49:42 +00:00
hsbt 6f3e8df133 * tool/rbinstall.rb: support to install bundle gems.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46513 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-23 09:13:14 +00:00
knu 4fa35e0e9d * lib/net/imap.rb (Net::IMAP#fetch): [DOC] Describe how a range in
+set+ is interpreted, and mention -1 which can be used for '*'.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46512 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-23 08:46:11 +00:00
shyouhei 8250aa2df0 * include/ruby/ruby.h (struct RHash): no longer. [Feature #9889]
* include/ruby/ruby.h (RHASH): ditto.

	* include/ruby/ruby.h (RHASH_ITER_LEV): deprecated.  Will be deleted later.

	* include/ruby/ruby.h (RHASH_IFNONE): ditto.

	* internal.h (struct RHash): moved here.

	* internal.h (RHASH): ditto.

	* hash.c (rb_hash_iter_lev): do not use this.

	* hash.c (rb_hash_ifnone): ditto.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46507 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-23 07:26:03 +00:00
shyouhei 62bfc4f24e * include/ruby/ruby.h (struct RComplex): no longer. [Feature #9888]
* include/ruby/ruby.h (RCOMPLEX): ditto.

	* include/ruby/ruby.h (RCOMPLEX_SET_REAL): deprecated.  Will be deleted later.

	* include/ruby/ruby.h (RCOMPLEX_SET_IMAG): ditto.

	* internal.h (struct RFloat): moved here.

	* internal.h (RCOMPLEX): ditto.

	* complex.c (rb_complex_set_real): do not use this.

	* complex.c (rb_complex_set_imag): ditto.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46506 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-23 04:41:27 +00:00
shyouhei 6adcf6a898 * include/ruby/ruby.h (struct RFloat): no longer. [Feature #9863]
* include/ruby/ruby.h (RFLOAT): ditto.

	* internal.h (struct RFloat): moved here.

	* internal.h (RFLOAT): ditto.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46505 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2014-06-23 04:12:19 +00:00