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

46960 Коммитов

Автор SHA1 Сообщение Дата
ko1 1d248f0429 use NULL instead of 0.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59154 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-23 05:55:12 +00:00
ko1 931cc441e5 skip on other threads (again).
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59153 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-23 05:52:28 +00:00
ko1 23206859bc revert r59151 which introduce failures.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59152 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-23 05:50:35 +00:00
ko1 25566b05fc skip on other threads.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59151 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-23 05:45:50 +00:00
glass 2fd3a2e2f7 Revert "Allow IO#reopen to take a block"
This reverts r59142.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59150 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-23 04:19:53 +00:00
nobu 02fa3456ce vm_insnhelper.c: vm_stack_consistency_error
* vm_insnhelper.c (vm_stack_consistency_error): extracted from
  insns.def for further info in the future.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59149 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-23 01:43:39 +00:00
svn 83d1fdeee5 * 2017-06-23
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59148 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-23 00:29:45 +00:00
nobu 6dc924b606 refinements.rdoc: [DOC] improved [Fix GH-1659]
* doc/syntax/refinements.rdocrefinements.rdoc: grammatical
  correction and code highlighting improved

* doc/syntax/refinements.rdocrefinements.rdoc: Fixnum replaced
  with Integer and Integer with Numeric

Author:    Shiva Bhusal <shivabhusal@users.noreply.github.com>

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59147 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-23 00:29:45 +00:00
nobu ae6ebbb3fa fix mortal_dynamic_symbol count
* test/objspace/test_objspace.rb (test_count_symbols): exclude a
  dynamic symbol which has been turned into immortal by
  define_method.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59146 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-22 12:53:05 +00:00
glass b906f78855 Fix exception type in option type checker
* lib/shell/system-command.rb (SystemCommand#initialize):
  `def_e2message` wraps error message, but does not define new exception

* test/shell/test_command_processor.rb: add a test

This patch is authored by Kenichi Kamiya <kachick1@gmail.com>
close #1657

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59145 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-22 10:56:49 +00:00
ko1 eb3ca69935 use --dump option for parse rule.
* common.mk: use --dump=--dump=parsetree_with_comment,insns
  instead of tool/parse.rb. maybe nobody use this option so that
  I believe it is enough. previous "parse" rule doesn't run script
  but patched parse rule runs specified script (on miniruby).


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59144 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-22 08:37:53 +00:00
ko1 dc44df8a06 try to fix symbol duplication.
* test/objspace/test_objspace.rb (test_count_symbols): make more complex dynamic
  symbols to avoid conflict with other existing static symbols.
  Sometimes this test fails with "mortal_dynamic_symbol=>127".



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59143 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-22 08:33:33 +00:00
glass f1b7003f35 Allow IO#reopen to take a block
* io.c (rb_io_reopen): take a block and ensure the IO closed
  [Feature #2631]

* test/ruby/test_io.rb: add a test

* NEWS: add an entry for this change

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59142 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-22 06:50:32 +00:00
svn 2a46ba9423 * remove trailing spaces.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59141 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-22 06:42:27 +00:00
ko1 de2ae27bd8 introduce heap_allocatable_pages_set().
* gc.c (heap_allocatable_pages_set): added. This function set
  heap_allocatable_pages and sorted_list atomically.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59140 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-22 06:42:26 +00:00
ko1 a48fecd3b9 catch up frozen_string_literal: true.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59139 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-22 05:51:43 +00:00
ko1 f736cf3274 introduce GC_ASSERT().
* gc.c (GC_ASSERT()): added. GC_ASSERT() is similar to VM_ASSERT in
  vm_core.h but turn on by RGENGC_CHECK_MODE.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59138 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-22 05:03:18 +00:00
svn d0b8fa7319 * 2017-06-22
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59137 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-22 00:59:55 +00:00
nobu 7a1c10ba08 gc.c: expand sorted pages
* gc.c (heap_page_allocate): expand sorted pages before inserting
  allocated new page.  [Bug #12670]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59136 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-22 00:59:54 +00:00
nobu ea57d84654 gc.c: FL_CHECK2
* gc.c (FL_TEST2, FL_SET2, FL_UNSET2): make error messages
  consitent.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59135 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-21 12:51:26 +00:00
eregon 5dc1055a58 * NEWS: Fix typo.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59134 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-21 10:06:44 +00:00
sonots 0d03650599 test/ruby/test_string.rb: add tests to chomp substr
* test/ruby/test_string.rb (TestString#test_chomp): add tests
  to chomp substr

* test/ruby/test_string.rb (TestString#test_chomp!): ditto

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59133 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-21 07:43:27 +00:00
sonots 10082360b9 string.c: add String#delete_prefix and String#delete_prefix!
to remove leading substr [Feature #12694] [fix GH-1632]

* string.c (rb_str_delete_prefix_bang): add a new method
  to remove prefix destuctively.

* string.c (rb_str_delete_prefix): add a new method
  to remove prefix non-destuctively.

* test/ruby/test_string.rb: add tests.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59132 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-21 07:43:26 +00:00
nobu 6af650256b RUBY_DEVEL flag
* configure.in: define RUBY_DEVEL only in the trunk.

* gc.c: enable runtime rgengc debug if RUBY_DEVEL

* ruby.c (debug_option): enable RUBY_DEBUG in --debug option only
  if RUBY_DEVEL.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59131 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-21 04:34:25 +00:00
nobu 5682bfe2d9 configure.in: use AS_IF
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59130 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-21 03:27:21 +00:00
nobu 793f5d8fe8 ruby.c: debug options in command line
* ruby.c (debug_option): parse options in --debug command line
  option same as RUBY_DEBUG env.  available only in the trunk.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59129 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-21 02:44:23 +00:00
nobu 9cacc53d4a 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>

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59128 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-21 02:25:27 +00:00
nobu 5eec76bc7b KNOWNBUGS.rb: hung up on linux
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59127 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-21 02:03:38 +00:00
nobu ed908e5c2b KNOWNBUGS.rb: deferred free
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59126 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-21 01:34:34 +00:00
nobu 477d115924 bootstraptest/runner.rb: keyword argument
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59125 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-21 01:34:33 +00:00
svn 1530dce8ac * 2017-06-21
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59124 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-20 15:23:51 +00:00
eregon 6f199eb803 Use a file under tmp for File.real{,dir}path specs on Windows
* The source file path could have pre-existing symlinks.
* See https://github.com/ruby/spec/issues/445.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59123 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-20 15:23:50 +00:00
hsbt 8ae9de372a Fixed missing handling for frozen object at r59121.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59122 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-20 11:43:05 +00:00
hsbt d5f86e836f Specify frozen_string_literal: true.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59121 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-20 11:10:37 +00:00
nobu b589c47806 gc.c: add newline to report [ci skip]
* gc.c (gc_sweep_finish): gc_report format should end with a
  newline, as gc_report_body does not append it.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59120 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-20 08:23:25 +00:00
svn 90846d7f4c * 2017-06-20
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59119 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-20 05:34:33 +00:00
ko1 4d932a68ff skip unresolved issue.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59118 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-20 05:34:33 +00:00
nobu 22c8dcffe1 debug.c: rgengc debug option
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59117 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-19 14:36:18 +00:00
nobu 263a0f7f16 test for [Bug #12670]
heap corruption by deferred free.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59116 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-19 14:36:17 +00:00
hsbt 0a907a3792 Make string literal to frozen object on gemspec of defulte gems.
Added following gemspecs.

    * extensions: date, dbm, etc, fiddle, gdbm, sdbm, stringio, strscan, zlib
    * pure ruby libraries: cmath, csv, fileutils, scanf, webrick

  psych and rdoc is out of scope of this commit. I will merge after
  upstream was change to `frozen_string_literal: true`.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59115 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-19 13:03:06 +00:00
svn 79f855716d * 2017-06-19
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59114 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-19 13:00:13 +00:00
eregon d404e271ae Adapt Time#zone spec to deal with differences of TZ validation on Windows
* [Bug #13591] [ruby-core:81347]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59113 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-19 13:00:12 +00:00
nobu f5052d45be string.c: check just before modification
* string.c (rb_str_chomp_bang): check if modifiable after checking
  an argument and just before modification, as it can get frozen
  during the argument conversion to String.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59112 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-18 04:38:01 +00:00
nobu 80aa1e6218 test_string.rb: chomp! frozen string
* test/ruby/test_string.rb (TestString#test_chomp): should raise
  if frozen.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59111 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-18 04:29:05 +00:00
nobu b89367d6d5 test/unit.rb: close jobserver
* test/lib/test/unit.rb (Test::Unit::Parallel#flush_job_tokens):
  close jobserver auth fds aflter flush, not to  release tokens
  more than acquired.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59110 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-18 04:29:04 +00:00
nobu bc08e66607 capi/spec_helper.rb: suppress logo
* spec/rubyspec/optional/capi/spec_helper.rb (compile_extension):
  suppress logo of nmake.exe to stderr.  we want to show compiler
  warnings only.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59109 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-18 01:15:36 +00:00
svn de4f844b85 * 2017-06-18
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59108 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-18 01:15:36 +00:00
nobu d4aad43f59 appveyor.yml: num of jobs
* appveyor.yml (test_script): stop running too many workers to get
  rid of sporadic NoMemoryError.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59107 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-18 01:15:35 +00:00
nobu 3947382b87 capi/spec_helper.rb: pass jobserver fds
* spec/mspec/lib/mspec/commands/mspec.rb (MSpecMain#multi_exec):
  do not close GNU make jobserver auth fds.

* spec/rubyspec/optional/capi/spec_helper.rb (compile_extension):
  ditto.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59106 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-17 00:18:33 +00:00
nobu 0955d9101c capi/spec_helper.rb: use MAKE env
* spec/rubyspec/optional/capi/spec_helper.rb (compile_extension):
  prefer MAKE environment variable to hardcoded name if set by
  parent make.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59105 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-17 00:10:54 +00:00