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

53297 Коммитов

Автор SHA1 Сообщение Дата
nobu b7fccecf1c Remove useless backslash
* lib/optparse.rb (OptionParser::Switch#compsys): remove useless
  backslash which just confuse ruby-mode.el.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66068 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-28 06:12:57 +00:00
normal e9dbafa5c8 test_settracefunc (test_tracepoint_enable_with_target_line): less fragile
Allow us to make other changes to the file and move the method
around without affecting this test.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66067 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-28 04:31:42 +00:00
hsbt 79dd244c3a Regenerated binstubs of bundler, rdoc and irb.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66066 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-28 03:10:09 +00:00
hsbt 5dbc6583c9 Merge rubygems upstream from 2c499655f2
https://github.com/rubygems/rubygems/pull/2493

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66065 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-28 03:08:14 +00:00
hsbt b52761e4f7 Merge stringio.gemspec from github repository.
Temporary ignored configuration of certificate sign.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66064 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-28 02:38:29 +00:00
duerst b4e39021f2 use create_sequence_node() once more
One more use of create_sequence_node() in node_extended_grapheme_cluster
(several more to come).

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66063 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-28 01:58:35 +00:00
k0kubun 110273c534 using_spec.rb: skip broken test for MinGW for now
ko1 is fixing this and he suggested to skip it for now

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66062 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-28 01:53:46 +00:00
shugo 6ec1720aa3 lib/monitor.rb: avoid race conditions by Thread.handle_interrupt
Suggested by Benoit Daloze.  [ruby-core:88502] [Bug #14998]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66061 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-28 01:51:44 +00:00
normal db7338fd75 io.c (rb_update_max_fd): use F_GETFL if possible
On 64-bit Linux, fstat() needs to fill out a 144 byte struct
while F_GETFL only needs to return 8 bytes.

Fwiw, F_GETFD requires an additional rcu_read_lock and bitmap
check; so it's obviously more expensive than F_GETFL on Linux.

Reduce stack usage of rb_update_max_fd from 184 to 24 bytes.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66060 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-28 01:10:40 +00:00
nobu c5fe904f6e Fix for coroutine/win32/Context.obj
* coroutine/win32/Context.asm: old ml version 9 needs CPU
  directive before `.model` directive.

* win32/Makefile.sub: specify object directories to separate Win32
  and Win64 targets.  Win32 rule was overridden by Win64 rule and
  just ignored.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66059 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-28 01:04:39 +00:00
nobu db67f542dc win32/Makefile.sub: add flags for AS
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66058 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-28 01:04:38 +00:00
duerst 97a8334cd3 introduce macro R_ERR to reduce repetitive code
Introduce a new preprocessor macro R_ERR to visually reduce repetitive code
checking for return values and going to the err: label at the end of the
function node_extended_grapheme_cluster().

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66057 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-28 00:53:35 +00:00
shyouhei 7cb0965822 .travis.yaml: unquote
It was probably me, 7 years ago, in r33844, who started overly
quoting YAML strings.  But now, this file grown up 50+ times from
6 lines to more than 300.  It is more annoying than convenient to
quote everything to add backslashes here and there.

Just use quotes only when necessary.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66056 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-28 00:49:24 +00:00
hsbt 14f47deacc Removed redundant empty line.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66055 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-28 00:48:21 +00:00
svn b75a4591c8 * expand tabs.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66054 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-28 00:35:27 +00:00
normal e432c52626 io.c: reduce IO.copy_stream stack usage on Linux
nogvl_copy_file_range and nogvl_copy_stream_sendfile each
used 344 bytes of stack before this change.  Now, they are
inlined into nogvl_copy_stream_func which only uses 200 bytes
of stack.

"struct stat" is 144 bytes on my 64-bit Linux.

Note: this doesn't affect GC (yet) since GVL is released;
but increases safety if called from deep machine stacks.

It will affect GC if Thread::Light is merged.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66053 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-28 00:35:22 +00:00
duerst 42cb4feda1 reduce number of arguments on quantify_property_node()
There are only four patterns of the last two arguments to quantify_property_node().
By replacing the lower/upper arguments with a single char, we get more expressive
calls, the last argument directly corresponding to the quantifier that we want to
use (except for '2', which means exactly two).

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66052 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-28 00:28:52 +00:00
kazu eaf9bc00ed Add Float::INFINITY or nil to call-seq of Enumerator::Chain#size [ci skip]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66051 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-27 23:57:55 +00:00
normal 7b5c2d3f9e enumerator.c (enum_chain_yield_block): use predefined ID
No point in having rb_intern lookup and cache a predefined ID

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66050 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-27 22:48:07 +00:00
normal a607c866dc io.c (struct copy_stream_struct): packing
Reduce the struct to 80 bytes (from 88) on amd64 to reduce
stack use.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66049 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-27 22:20:45 +00:00
duerst 7c4a422d83 fix order of subexpressions for Hangul
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66048 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-27 21:50:27 +00:00
svn 793c48b4ce * remove trailing spaces.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66047 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-27 21:38:55 +00:00
duerst 06bd42a722 introduce two more uses of create_sequence_node in node_extended_grapheme_cluster
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66046 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-27 21:38:53 +00:00
duerst 99d451f5c5 correctly handle return value from create_sequence_node()
In function node_extended_grapheme_cluster(), store and test
return value from create_sequence_node(). Never forget this!

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66045 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-27 21:23:11 +00:00
svn 87cda89ca7 * remove trailing spaces.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66044 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-27 21:12:31 +00:00
duerst 8186889120 declare array for sequence at start of code creating sequence
In function node_extended_grapheme_cluster(),
move declaration up so that block encompasses all of the regular expression
creation that finally makes up the sequence. Having blocks like this will
be great because it directly shows the extent of code belonging to each
subexpression of the regular expression being created.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66043 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-27 21:12:29 +00:00
duerst 7086aae378 make sure all nodes are correctly freed in create_property_node()
We make sure that the newly created tree and all remaining nodes passed in
in the node_array are freed.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66042 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-27 21:00:06 +00:00
eregon 50441014ff Update to ruby/spec@cdd6ff7
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66041 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-27 20:38:57 +00:00
svn 49cd16bfaf * 2018-11-28
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66040 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-27 20:38:21 +00:00
eregon eae7fbb682 Update to ruby/mspec@820486a
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66039 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-27 20:38:20 +00:00
nobu 047111584f ruby-style.el: ruby-style-c-mode by VCS [ci skip]
* misc/ruby-style.el (ruby-style-c-mode): set ruby-style if the
  remote repository is ruby.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66038 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-27 13:47:49 +00:00
svn 5bc8bb36c9 * properties.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66037 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-27 12:08:21 +00:00
hsbt fc9509bdd2 Merge bundler-2.0.0.pre.2 from upstream.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66036 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-27 12:08:19 +00:00
k0kubun 86cb3d319f mjit_worker.c: promote mjit_copy_job from function
-local variable to global variable.

Consider this case:
1. MJIT worker: dequeue ISeq (stop_worker_p was still FALSE)
2. Ruby thread: call Kernel#exec, which calls mjit_finish(FALSE),
                sets `stop_worker_p = TRUE`, and fires RUBY_VM_CHECK_INTS() once
3. MJIT worker: register copy job, but found stop_worker_p is TRUE.
                set `worker_stopped = TRUE` and the thread stops.
4. Function-local job variable expires by the thread stop (this is eliminated by this commit)
5. Ruby thread: find `worker_stopped` becamse TRUE, start Kernel#exec.
                Kernel#exec fails but exception is rescued.
6. Ruby thread: call RUBY_VM_CHECK_INTS. copy job is dispatched but job variable
                is already expired.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66035 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-27 12:00:51 +00:00
k0kubun c3fe307808 regparse.c: conform C90
../regparse.c:5908:28: error: initializer for aggregate is not a compile-time constant [-Werror,-Wc99-extensions]
      Node* sequence[] = { np1, np2, np3, ((Node* )0) };
                           ^~~

https://travis-ci.org/ruby/ruby/jobs/460197620

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66034 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-27 11:24:19 +00:00
duerst 9e2455b756 introduce helper function create_sequence_node()
The new function create_sequence_node() uses its second argument
(an array of Node*, from left to right, ending with NULL_NODE)
to create a sequence of expressions using node_new_list().

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66033 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-27 11:04:02 +00:00
svn 231930ca7d * remove trailing spaces.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66032 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-27 10:15:46 +00:00
duerst 8f9c00d207 introduce helper function quantify_property_node()
The new function quantify_property_node() combines the functions
create_property_node() and quantify_node(), which frequently appear together.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66031 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-27 10:15:45 +00:00
duerst 69443998cd introduce helper function quantify_node() to wrap function node_new_quantifier
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66030 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-27 09:44:35 +00:00
nobu 186ff0eb3e .travis.yml: avoid bashism
GCC_FLAGS is not an array and CC is finally passed to configure as
single string.  Pass CC via the environment variable, so it does
not need to be quoted anymore.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66029 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-27 08:39:40 +00:00
nobu b6854df429 .travis.yml: discard config.cache if CC changed
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66028 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-27 08:39:39 +00:00
nobu b6f73c9034 .travis.yml: split commands
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66027 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-27 08:39:38 +00:00
svn a1c4e0c96b * expand tabs.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66026 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-27 07:34:25 +00:00
mame b7561dafb9 compile.c: prevent out-of-bound initialization of coverage counters
The coverage counters is initialized with `counter[lineno - 1] = 0`,
but lineno may be 0, which led to write access for index -1.
[ruby-core:90085] [Bug#15346]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66025 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-27 07:34:21 +00:00
aycabta 4beec66757 Merge rdoc-6.1.0.bata2
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66024 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-27 07:02:36 +00:00
nobu 7aaf5b2878 Embed the Emoji version
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66023 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-27 06:44:02 +00:00
ko1 b02f3731b6 restore using_spec.rb
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66022 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-27 05:42:33 +00:00
duerst aa44935969 use explicit property name when creating nodes for "Grapheme_Cluster_Break=Extend"
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66021 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-27 04:13:21 +00:00
duerst b62e466fb5 use 'Regional_Indicator' script property instead of fixed constants
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66020 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-27 03:56:19 +00:00
nobu b549d14c00 Add rb_typeddata_is_instance_of
Similar to rb_typeddata_is_kind_of, except for that inherited type
is not an instance.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66019 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-27 03:19:06 +00:00