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

47081 Коммитов

Автор SHA1 Сообщение Дата
hsbt 24873d1a05 Use Test::Unit::TestCase instead of MiniTest::Unit::TestCase. Because
tests of fiddle already used customized assertions of ruby core.

  * test/fiddle/helper.rb: Use Test::Unit::TestCase for base class of
    testcase.
  * test/fiddle/test_*.rb: Use assert_raise instead of assert_raises.
    Remove needless includes for Test::Unit::Assertions.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59321 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-13 09:46:16 +00:00
nobu 52e8254b54 parse.y: flush debug output
* parse.y (parser_compile_error): flush debug output before
  compile error message, to keep the order.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59320 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-13 07:00:16 +00:00
normal d15cc7a6a3 doc/extension.rdoc: update wikipedia link to HTTPS
Avoid the latency for HTTP -> HTTPS redirect

* doc/extension.rdoc: update wikipedia link to HTTPS

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59319 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-12 18:31:07 +00:00
svn 98f0a52845 * 2017-07-13
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59318 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-12 15:02:10 +00:00
kazu b25b9d4531 Fix indent [ci skip]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59317 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-12 15:02:09 +00:00
nobu b226a8b080 disable r59314 on mswin
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59315 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-12 09:44:45 +00:00
nobu 5bdb4e0566 gc.c: restrict RGENGC_DEBUG
* gc.c (RGENGC_DEBUG_ENABLED): restrict runtime ruby_rgengc_debug
  level up to -RGENGC_DEBUG, to reduce runtime branches in inner
  loops.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59314 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-12 05:30:43 +00:00
svn 5235446a31 * 2017-07-12
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59313 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-12 02:49:54 +00:00
nobu 89bf90a370 optparse.rb: get rid of eval
* lib/optparse.rb: try Float() and Integer() instead of eval,
  which does too much things.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59312 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-12 02:49:53 +00:00
svn 561c253512 * 2017-07-11
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59311 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-11 07:42:27 +00:00
ko1 5168fb54e3 tainted string should be tainted.
* hash.c (hash_aset_str): create frozen string for tainted objects.
  (should not use fsting table on this case).


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59310 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-11 07:42:27 +00:00
nobu d2dd18ed16 compile.c: simplify defined_expr0
* compile.c (defined_expr0): exapnd defined_expr macro.

* compile.c (defined_expr0): reduce duplicate code.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59309 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-10 11:42:07 +00:00
nobu 5ed1d88eda test_rubyoptions.rb: assert -00
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59308 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-10 07:37:18 +00:00
takano32 7aa74a0d0a a64: fix crash on register stack mark/sweep pass
* thread_pthread.c: move 'register_stack_start' earlier.
  [ruby-core:79928] [Bug #13284] [Fix GH-1625]

Author:    Sergei Trofimovich <slyfox@gentoo.org>


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59307 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-10 06:57:50 +00:00
nobu f1fe99b1be hash.c: prefer value cast to pointer cast
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59306 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-10 00:41:21 +00:00
svn 9d1d30c911 * 2017-07-10
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59305 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-09 23:04:44 +00:00
normal e205304a3e Hash#[]= deduplicates string keys if (and only if) fstring exists
In typical applications, hash entries are read after being
written to.  Blindly writing to hashes which are never read
makes little sense. So, for any hash which is read from, an
fstring entry for the key should already exist for the key.

We no longer blindly create fstrings if the code is blindly
setting random hash keys, preventing the performance regression
in the reverted r43870.

Regarding <https://bugs.ruby-lang.org/issues/9188>, this has a
minimum impact on the bm_so_k_nucleotide where hash keys are set
and not reused, performance is within 1-2% of existing cases.

* hash.c: #include gc.h for rb_objspace_garbage_object_p
  (hash_aset_str): do read-only check of fstring table and
  reuse fstring if it exists and is still alive (not garbage)
  [ruby-core:81942] [Feature #13725]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59304 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-09 23:04:43 +00:00
nobu b391708718 downloader.rb: get rid of symlinks in dist files
* tool/downloader.rb: download to the target file directly if
  CACHE_SAVE=no, to get rid of symlinks in dist files.
  [ruby-core:81887] [Bug #13709]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59292 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-09 04:49:15 +00:00
nobu 90d65afc92 make-snapshot: generate ChangeLog iff not exist
* tool/make-snapshot (package): ChangeLog had existed in pre-2.4
  revisions, but not doc/ChangeLog-YYYY.  fix for 2..3.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59291 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-09 04:20:48 +00:00
svn ac9219e010 * 2017-07-09
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59290 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-09 04:17:50 +00:00
nobu d0677cdb2c make-snapshot: touch-unicode-files for 2.4
* tool/make-snapshot (package): fallback touch-unicode-files for
  2.4, which has been introduced to reduce downloads on CI.
  [ruby-core:81972] [Bug #13734]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59289 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-09 04:17:49 +00:00
nobu 2abf6a3474 * template/exts.mk.tmpl: extract SUBMAKEOPTS from sub exts.mk files too. [Bug #13730]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59288 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-08 12:31:55 +00:00
nobu 1d6c1d20fd assertions.rb: syntax_check for other impl
* test/lib/test/unit/assertions.rb (syntax_check): use eval
  instead of RubyVM::InstructionSequence.compile so that other
  implementations can share the tests.
  [ruby-core:81935] [Bug #13723]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59287 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-08 02:22:20 +00:00
nobu 41bdfc53da .travis.yml: update dist to trusty
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59285 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-08 02:05:55 +00:00
normal 129a071112 NEWS: note [Feature #13517] is Linux-only (no side-effects on _*nonblock)
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59284 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-07 17:59:09 +00:00
normal 61a8b4c1ce NEWS: entry for WEBRick SNI support [Feature #13729]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59283 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-07 17:41:08 +00:00
svn c82bed6324 * properties.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59282 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-07 17:09:40 +00:00
normal 08bdbef5ca webrick: add Server Name Indication (SNI)
* lib/webrick/https.rb: servername_cb implementation.
* lib/webrick/ssl.rb: abstract servername_cb.
* test/webrick/test_https.rb: test.
  [ruby-dev:50165] [Feature #13729]
  Author: Tietew <tietew@gmail.com>

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59281 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-07 17:09:39 +00:00
svn 4d3d6f6898 * 2017-07-08
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59280 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-07 16:53:04 +00:00
normal aff529a5ff webrick: become maintainer
<CAK6HhsrshX7s3qai4usbXknTQnA4GoRThJcQ_Ea=WgTG2Gu0QA@mail.gmail.com>

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59279 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-07 16:53:03 +00:00
nobu d984da6649 Run single downloader
* common.mk (update-unicode-property-files, update-unicode-files):
  download in single process for each targets, not for each files
  in parallel, to get rid of conflicts.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59278 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-07 12:25:49 +00:00
svn c61342141f * 2017-07-07
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59276 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-07 02:14:58 +00:00
usa b88e0ceb85 * tool/redmine-backporter.rb (show): just report and ignore if a feature ticket
is specified instead of aborting.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59275 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-07 02:14:57 +00:00
nobu 8ddf0263bb Fix DecimalInteger converting to octal bug
Previously if the input started with a '0' then it will be converted
as octal even though it has been specified as a decimal. This commit
forces the number to be interpreted as a decimal.

[ruby-core:81927] [Bug #13722] [Fix GH-1665]
Author:    william <william.mccumstie@outlook.com>

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59273 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-06 11:49:03 +00:00
rhe 06a3a10acf string.c: preserve coderange in String#setbyte
Fix a wrong jump so replacing a byte in an ASCII-only string with an
ASCII character won't clear the coderange.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59272 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-06 07:21:17 +00:00
rhe 2c8cec96cc string.c: remove dead code in str_fill_term()
The length of a string never exceeds the capacity.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59271 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-06 07:21:16 +00:00
svn 1798deb210 * 2017-07-06
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59270 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-06 04:12:52 +00:00
nobu d9d8ca0b8f lexer.rb: ignore dedented space
* ext/ripper/lib/ripper/lexer.rb (on_heredoc_dedent): replace an
  empty string content because of dedentation with :on_ignored_sp.
  an empty token makes the sorted order unstable.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59269 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-06 04:12:51 +00:00
rhe 650e758060 un.rb: use OpenSSL::PKey.read instead of OpenSSL::PKey::RSA.new
Also, error out if --ssl-private-key option is not given, since
specifying only the certificate makes no sense.  [Feature #13714]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59268 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-05 09:05:53 +00:00
nobu af683bd16c debug.c: add FMODE constants
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59266 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-05 06:32:54 +00:00
nobu 2c59dd61f1 un.rb: support https
* lib/un.rb: add https support.  based on the patch by Flavio
  Castelli <flavio@castelli.name> in [ruby-core:81901].
  [Feature #13714]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59265 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-05 06:27:43 +00:00
normal 6899d6a98c tool/mk_call_iseq_optimized.rb: fix generated comment
"tool/mkcall_iseq.rb" never existed in our repo.

* tool/mk_call_iseq_optimized.rb: fix generated comment

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59264 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-04 17:27:40 +00:00
svn 9e5e93f590 * properties.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59263 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-04 16:02:20 +00:00
mame f85bc2906b Use lcov visualizer for gcov statistics
This experimental feature is only for Ruby-core team, not for casual users.

Usage: `./configure --enable-gcov && make && make exam && make lcov`

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59262 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-04 16:02:19 +00:00
svn 2b8bf0fc4a * 2017-07-05
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59261 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-04 16:02:18 +00:00
mame 0ee154bee2 tool/run-gcov.rb: ignore rubyspec_temp directory
rubyspec compiles the extension libraries for capi specs in a temporary
directory, and after that, deletes the directory.  gcov resurrects the
directory to save coverage statistics (.gcda files).  However, the
source and profiling artifacts (.gcno files) have been deleted.
So, we need to ignore the .gcda files.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59260 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-04 16:02:18 +00:00
nobu 1c34f0b837 vm_args.c: improve keyword argument errors
* vm_args.c (argument_arity_error): improve required keyword
  argument errors when non-keyword arguments given.
  [ruby-core:79439] [Bug #13196]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59259 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-04 05:42:04 +00:00
nobu 202fbe3046 time.c: preserve marshalled timezone
* time.c (time_add): preserve timezone name restored by Marshal.
  [ruby-core:81892] [Bug #13710]

* time.c (time_mload): reset localtime if having timezone.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59258 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-04 04:23:06 +00:00
svn 38c6daaabb * 2017-07-04
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59257 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-03 23:42:13 +00:00
nobu da373e5394 win32.c: restrict cursor move
* win32/win32.c (constat_apply): restrict cursor move in visible
  screen only.  [ruby-core:81883] [Bug #13707]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59256 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-07-03 23:42:12 +00:00