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

53312 Коммитов

Автор SHA1 Сообщение Дата
shyouhei 493955c692 .travis.yml: cache unicode.org files
Before this changeset (since r58071) we did not download files
from unicode.org but just touch some files.  This is a kind of
hack that people normally don't do at home.

We are caching other files between builds now.  Why not also save
those files downloaded from elsewhere.  This covers more
realistic workload, I guess.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66085 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-29 05:26:05 +00:00
shyouhei 2be1cf45c1 .travis.yml: fix YAML parse error
`[` is a meta character in YAML.  `- [` starts an array,
so it should end with `]`; but it was not.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66084 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-29 02:47:36 +00:00
svn 58d744461c * 2018-11-29
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66083 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-29 01:09:49 +00:00
nobu 8ea6c92eb3 time.rb: Move documents and stop others
* lib/time.rb: Move method documents to each methods.  And stop
  documentation of the abstract and others, which were confusingly
  placed at the top of generated documents prior to the abstract
  in time.c.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66082 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-29 01:09:47 +00:00
nobu 5a9066f22a Executable scripts have been moved to libexec [ci skip]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66081 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-28 14:56:19 +00:00
nobu 4471d4a3e5 time.c: rescue find_timezone when loading
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66080 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-28 14:08:35 +00:00
nobu 2d0833e101 Try with TZInfo and Timezone gems
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66079 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-28 14:08:34 +00:00
nobu ab73b30539 Time.at in: tz
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66078 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-28 14:08:33 +00:00
nobu bdfc701b85 Timezone at Time.at
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66077 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-28 14:08:32 +00:00
nobu 337b4b6344 Try Time.find_timezone to convert name to timezone
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66076 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-28 14:08:31 +00:00
nobu fe08f99e93 Try Time.find_timezone to load
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66075 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-28 14:08:30 +00:00
duerst c80aeb527e remove two unnecessary variables (np2 and np3)
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66072 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-28 07:07:59 +00:00
duerst d3b7a10dcc eliminate intermediate variable in very short block (3 times)
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66071 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-28 06:43:57 +00:00
duerst 33c7fa6501 use create_sequence_node() four more times
Four more use of create_sequence_node() in node_extended_grapheme_cluster
(a few more to come).

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66070 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-28 06:21:52 +00:00
nobu 2d67a3f4b1 Get rid of block-less Proc.new
* lib/optparse.rb (OptionParser::Switch#initialize): get rid of
  `Proc.new` without a block, which may be deprecated in the future.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66069 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-11-28 06:12:58 +00:00
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