Commit graph

63661 commits

Author SHA1 Message Date
Koichi Sasada
a770b9c87e remove debug code 2020-10-10 04:46:09 +09:00
Soutaro Matsumoto
02e17d473a
Let bundled_gems specify commits to test (#3641) 2020-10-09 18:41:20 +09:00
Nobuyoshi Nakada
8d1b188864
Refactored lex_context management
Save and restore `lex_context` as-is wholely, and save in
`k_class` and `k_module` to workaround look-ahead reading.
2020-10-09 13:44:48 +09:00
Nobuyoshi Nakada
9ee99fbd8a
rb_const_set sets the class path now 2020-10-09 12:03:52 +09:00
Nobuyoshi Nakada
6944b927bd
rb_class_real never returns Qnil 2020-10-09 11:49:13 +09:00
Aaron Patterson
bca8952fc7
Fix lldb disassembler so it works with core files
This fixes the lldb disassembler script so that it doesn't need a live
process when disassembling rb_iseq_t.  I also added the PC to the output
so you can tell what the VM is executing when it crashed.

For example:

```
(lldb) rbdisasm ec->cfp->iseq
PC             IDX  insn_name(operands)
0x56039f0a1720 0000 nop
0x56039f0a1728 0001 getlocal_WC_1( 5 )
0x56039f0a1738 0003 branchunless( 7 )
0x56039f0a1748 0005 getlocal_WC_0( 3 )
0x56039f0a1758 0007 putstring( (VALUE)0x56039f0c7eb8 )
0x56039f0a1768 0009 opt_send_without_block( (struct rb_call_data *)0x56039f09f140 )
0x56039f0a1778 0011 pop
0x56039f0a1780 0012 getglobal( ID: 0x7fd7 )
0x56039f0a1790 0014 branchunless( 7 )
0x56039f0a17a0 0016 getlocal_WC_0( 3 )
0x56039f0a17b0 0018 putstring( (VALUE)0x56039f0c7e90 )
0x56039f0a17c0 0020 opt_send_without_block( (struct rb_call_data *)0x56039f09f150 )
0x56039f0a17d0 0022 pop
0x56039f0a17d8 0023 getlocal_WC_0( 3 )
0x56039f0a17e8 0025 putobject( (VALUE)0x56039f0c7e68 )
0x56039f0a17f8 0027 getlocal_WC_1( 6 )
0x56039f0a1808 0029 dup
0x56039f0a1810 0030 checktype( 5 )
0x56039f0a1820 0032 branchif( 4 )
0x56039f0a1830 0034 dup
0x56039f0a1838 0035 opt_send_without_block( (struct rb_call_data *)0x56039f09f160 )
0x56039f0a1848 0037 tostring
0x56039f0a1850 0038 putobject( (VALUE)0x56039f0c7e40 )
0x56039f0a1860 0040 concatstrings( 3 )
0x56039f0a1870 0042 opt_send_without_block( (struct rb_call_data *)0x56039f09f170 )
0x56039f0a1880 0044 nop
0x56039f0a1888 0045 leave
(lldb) p ec->cfp->pc
(const VALUE *) $146 = 0x000056039f0a1848
```

Here we can see the VM is currently executing `opt_send_without_block`
(because the PC is one ahead of the current instruction)
2020-10-08 16:43:11 -07:00
git
c857d0d471 * 2020-10-09 [ci skip] 2020-10-09 05:35:37 +09:00
Burdette Lamar
33776598f7
Enhanced RDoc for String#insert (#3643)
* Enhanced RDoc for String#insert
2020-10-08 15:35:13 -05:00
Hiroshi SHIBATA
533bca57e0
Expose assert, assert_respond_to and assert_not_respond_to for default gems. 2020-10-08 16:40:46 +09:00
Hiroshi SHIBATA
0f9edf2f48
Promote prettyprint to default gems 2020-10-08 16:40:46 +09:00
Hiroshi SHIBATA
2711e3bab9
Promote pp to default gems 2020-10-08 16:40:46 +09:00
git
0807d05d6e * 2020-10-08 [ci skip] 2020-10-08 09:01:36 +09:00
Aaron Patterson
d528254095
Add missing WB for iseq
The write barrier wasn't being called for this object, so add the
missing WB.  Automatic compaction moved the reference because it didn't
know about the relationship (that's how I found the missing WB).
2020-10-07 17:01:14 -07:00
Nobuyoshi Nakada
62abdbadf2
Revert "Don't export rb_callable_receiver"
This reverts commit c839168b11.
`rb_callable_receiver` does not need to be exposed under include.
2020-10-07 11:27:30 +09:00
Aaron Patterson
cdc4084b0a Prevent objects from moving while iterating the heap
This iterator uses an st_table, but if objects move the references in
the st table won't be updated.  This patch just changes the st table to
an identity hash.
2020-10-06 16:22:01 -07:00
Chris Seaton
c839168b11 Don't export rb_callable_receiver 2020-10-06 15:41:47 -07:00
Chris Seaton
fef52122b0 Use proc_binding rather than rb_funcall
FIX
2020-10-06 15:41:47 -07:00
Aaron Patterson
ee7cc6ac35
Make marshal_load public
Ruby specs expected this method to be public
2020-10-06 15:13:49 -07:00
Marc-Andre Lafortune
1486785a57 [lib/ostruct] Fix Marshal loading 2020-10-06 17:11:08 -04:00
git
260322fbc5 * 2020-10-07 [ci skip] 2020-10-07 00:04:48 +09:00
Nobuyoshi Nakada
ed01cc8fdc
No longer need libtool
As debug_counter.c has had a global symbol since cdc614cd0a,
ranlib should no longer complain that it has no symbols.
2020-10-06 23:46:24 +09:00
Nobuyoshi Nakada
21b199bb24
Appended a newline to suppress newline-eof warning 2020-10-06 23:18:42 +09:00
卜部昌平
2d20e68fb7 include/ruby/memory_view.h: annotate functions 2020-10-06 14:20:10 +09:00
卜部昌平
62ddbfe2b9 rb_memory_view_is_contiguous: convert into an inline function 2020-10-06 14:20:10 +09:00
卜部昌平
ae94c5bf5d STRUCT_ALIGNOF: use RUBY_ALIGNOF
This was a workaround for RUBY_ALIGNOF's glitch, which has already been
fixed.  See also https://github.com/ruby/ruby/pull/3570
2020-10-06 14:20:10 +09:00
卜部昌平
7d594399f6 memory_view.h: use bool
Because `bool` is already used in the header there is no reason to
hesitate.
2020-10-06 14:20:10 +09:00
卜部昌平
81068b1090 RB_RANDOM_DATA_INIT_PARENT: convert into an inline function
Bit readable to me.
2020-10-06 14:20:10 +09:00
卜部昌平
78e27ced97 rb_rand_if: convert into an inline function
This adds more room for assertions.
2020-10-06 14:20:10 +09:00
卜部昌平
56a45456ac include/ruby/random.h: eliminate extern "C"
cf: 99add25857
2020-10-06 14:20:10 +09:00
Kazuhiro NISHIYAMA
45fd4436ee Use $GITHUB_ENV instead of set-env
https://github.blog/changelog/2020-10-01-github-actions-deprecating-set-env-and-add-path-commands/
2020-10-06 11:41:17 +09:00
Kazuhiro NISHIYAMA
f9df340a6a Remove unused commit_info 2020-10-06 11:41:17 +09:00
Nobuyoshi Nakada
68d24bc045
Moved rb_callable_receiver internal 2020-10-06 10:11:51 +09:00
David Rodríguez
29c54b5e03
Add missing fileutils require
On my system, the error was being hidden by the presence of a YARD
rubygems plugin that was providing the require and making things work.
2020-10-06 10:10:42 +09:00
git
49bfd88976 * 2020-10-06 [ci skip] 2020-10-06 02:17:57 +09:00
Benoit Daloze
7d8b43d2ed [ruby/tempfile] Improve the documentation for Tempfile.create and recommend Tempfile.open instead
8bac025065
2020-10-05 19:17:25 +02:00
Svyatoslav Kryukov
3a3000f577 Fix traditional Ring example in Actor-model 2020-10-05 10:35:11 -04:00
aycabta
20ad101701 Remove system method for E2E testing because depends on ruby command 2020-10-05 19:50:31 +09:00
Nobuyoshi Nakada
82f496a84b
Put an empty line before the original URL
Even if the raw commit log does not end with a newline.
Suggested to use `grep` by znz.

Co-Authored-By: Kazuhiro NISHIYAMA <zn@mbf.nifty.com>
2020-10-05 17:32:36 +09:00
git
d5ab1979f7 * 2020-10-05 [ci skip] 2020-10-05 04:32:09 +09:00
aycabta
9718ff62c1 Show stdout and stderr when history tests fail 2020-10-05 04:17:26 +09:00
git
f8c50109d7 * 2020-10-04 [ci skip] 2020-10-04 23:00:53 +09:00
Nobuyoshi Nakada
ef4ba517e4
Adjusted default gems paths
* sync_default_gems.rb (sync_lib): sync from the same directory as
  sync_default_gems.
2020-10-04 22:55:27 +09:00
Koichi Sasada
0406898a3f add NULL check.
DATA_PTR(ractor) can be NULL just after creation.
2020-10-03 23:22:17 +09:00
Benoit Daloze
d0778cb264 Update example to handle keywords passed to Warning.warn 2020-10-03 13:19:24 +02:00
Nobuyoshi Nakada
fced98f464
Added the room for builtin inline prefix 2020-10-03 12:19:56 +09:00
Nobuyoshi Nakada
5a665f6ce7
Check builtin inline function index overflow 2020-10-03 10:47:24 +09:00
Aaron Patterson
6aa466ba9c mark regex internal to string scanner 2020-10-02 12:01:57 -07:00
Kazuhiro NISHIYAMA
873c8a14f0
Fix assert_ruby_status usage in 174ae0f577 2020-10-03 03:05:21 +09:00
Benoit Daloze
112254d185 Improve docs of the Warning module 2020-10-02 18:32:42 +02:00
Nobuyoshi Nakada
174ae0f577
Remove known use-after-poison bug
9eda654781 was fixed by
b9488accf9.
2020-10-03 00:45:06 +09:00