Jeremy Evans
7582287eb2
Make String#-@ not freeze receiver if called on unfrozen subclass instance
...
rb_fstring behavior in this case is to freeze the receiver. I'm
not sure if that should be changed, so this takes the conservative
approach of duping the receiver in String#-@ before passing
to rb_fstring.
Fixes [Bug #15926 ]
2019-07-02 08:26:50 -07:00
Jeremy Evans
ced640951b
Implement Array#minmax
...
Array#minmax was previous not implemented, so calling #minmax on
array was actually calling Enumerable#minmax. This is a simple
implementation of #minmax by just calling rb_ary_min and
rb_ary_max, which improves performance significantly.
Fixes [Bug #15929 ]
2019-07-02 08:07:06 -07:00
Yusuke Endoh
649753b7f5
Fix timezone issue for logger period's tests
...
This is a retry of 181b966e75
.
"Revert "Add a missing tests for Logger::Period module"" is also
reverted.
2019-07-02 15:50:12 +01:00
Koichi Sasada
f1043090a2
Revert "Add a missing tests for Logger::Period module"
...
This reverts commit 181b966e75
.
2019-07-02 23:38:25 +09:00
Takashi Kokubun
ea30dd7025
Avoid corrupting VM stack on inlined setlocal
...
setlocal relies on cfp->ep, and frame-omitted method inlining introduced
in Ruby 2.7 kept it wrong.
This change might slow down frame-omitted method inlining for cfp->ep
manipulation, and it obviously complicates the implementaion more. By
introducing an optimization that changes Ruby's local variable to C
local variable, we could optimize it and simplify the cfp->ep
manipulation later.
[Bug #15971 ]
2019-07-02 23:35:52 +09:00
Anton Davydov
181b966e75
Add a missing tests for Logger::Period module
...
Closes: https://github.com/ruby/ruby/pull/2266
2019-07-02 14:56:58 +01:00
Nobuyoshi Nakada
e9ea494171
The behavior of statx(2) depends on the filesystem
...
birthtime may not be supported on some filesystems, and
NotImplementedError can be raised. [Bug #15972 ]
2019-07-02 22:11:23 +09:00
Nobuyoshi Nakada
6ffef8d459
Clean up temporary expired cert file
2019-07-02 15:02:16 +09:00
Nobuyoshi Nakada
92dcee393a
Clean up temporary directory for racc
2019-07-02 15:02:16 +09:00
Hiroshi SHIBATA
7f3bc3529b
Adjust jit_support file path.
2019-07-02 09:56:17 +09:00
Nobuyoshi Nakada
832b509472
with_different_ofs.rb has been moved too
2019-07-02 09:43:33 +09:00
Nobuyoshi Nakada
b7fdeedbfd
Renamed to get rid of name clash
2019-07-02 09:31:32 +09:00
Hiroshi SHIBATA
897b1e0562
Fixed the wrong path for COVERAGE.
...
ref. c3c0e3f5c9
2019-07-02 08:00:29 +09:00
Hiroshi SHIBATA
c68781e918
Split test files for test-framework that are test-unit and minitest to tool direcotry.
2019-07-02 07:59:54 +09:00
Hiroshi SHIBATA
c3c0e3f5c9
Move to tool/lib from test/lib.
2019-07-02 07:59:54 +09:00
Jeremy Evans
f53d7e4bfd
Raise TypeError if calling ENV.freeze
...
Previously, you could call ENV.freeze, but it would not have
the desired effect, as you could still modify ENV.
Fixes [Bug #15920 ]
2019-07-01 12:39:06 -07:00
Nobuyoshi Nakada
78ee2c2453
marshal.c: check instance variable count
...
* marshal.c (w_ivar_each): ensure that no instance variable was
removed while dumping other instance variables. [Bug #15968 ]
2019-07-01 16:20:03 +09:00
Nobuyoshi Nakada
c9423b016c
marshal.c: check instance variable count
...
* marshal.c (w_obj_each): ensure that no instance variable was
added while dumping other instance variables. [Bug #15968 ]
2019-07-01 15:02:27 +09:00
Nobuyoshi Nakada
99dc885974
Fixed inadvertent ID creation in rb_iv_get
2019-07-01 13:56:55 +09:00
Nobuyoshi Nakada
6982a9049e
Assert obsolete method warnings in IPAddr
2019-07-01 13:02:23 +09:00
Nobuyoshi Nakada
f13fb814e0
Return the result of the block given to assert_warning/assert_no_warning
2019-07-01 00:22:39 +09:00
Nobuyoshi Nakada
51b2b605e7
Call deprecated method only inside assert_warning block
2019-07-01 00:22:39 +09:00
Nobuyoshi Nakada
9cb58f1698
Suppress unused variable warning
2019-07-01 00:22:38 +09:00
Nobuyoshi Nakada
8640153e59
Added test for require-return hook
2019-06-30 21:21:06 +09:00
Nobuyoshi Nakada
1eca2f3ca9
TracePoint#__enable requires 3 arguments now
2019-06-30 21:20:16 +09:00
Nobuyoshi Nakada
62e66b8e18
Allow dtrace without pty, i.e., with miniruby
2019-06-30 21:15:56 +09:00
Nobuyoshi Nakada
b89f6ac843
Check for the privileges by the current process groups
...
Group membership of login user is not activated until login after
adding to the group.
2019-06-30 21:12:15 +09:00
Nobuyoshi Nakada
3b86ec2251
dtrace: check for the command availablity with sudo
2019-06-30 20:56:49 +09:00
Nobuyoshi Nakada
126cf11d33
Producer threads check is the primary condition
2019-06-30 20:19:21 +09:00
Nobuyoshi Nakada
75129c62eb
Suppress "statement not reached" warning
2019-06-30 11:53:02 +09:00
Nobuyoshi Nakada
cc68084652
Suppress method redefinition warnings
2019-06-30 11:49:41 +09:00
Nobuyoshi Nakada
5f736d4319
Suppress "literal in condition" warnings
2019-06-30 11:49:40 +09:00
Nobuyoshi Nakada
4a063546e7
Suppress unused literal warnings in verbose mode
2019-06-30 11:49:40 +09:00
Nobuyoshi Nakada
3620568d3a
Suppress void context warnings in verbose mode
2019-06-30 11:49:40 +09:00
Nobuyoshi Nakada
c400c0b4a0
Skip instead of return
2019-06-30 11:45:38 +09:00
Nobuyoshi Nakada
b43d6e5709
Fixed non-working test
2019-06-30 11:45:38 +09:00
Nobuyoshi Nakada
8fe3590864
Fixed ClosedQueueError by a timing issue
2019-06-30 11:45:38 +09:00
Nobuyoshi Nakada
44eca1b22f
Reset the result between assertions
2019-06-30 11:45:38 +09:00
Nobuyoshi Nakada
ad3820886b
Fixed an assertion
2019-06-30 11:45:37 +09:00
Nobuyoshi Nakada
409b0ec4c3
Suppress unused variable warnings
2019-06-30 11:45:37 +09:00
Nobuyoshi Nakada
84837e6d16
Wait for the helper thread to terminate
2019-06-30 11:41:10 +09:00
Nobuyoshi Nakada
41012f2e2b
Add parentheses to suppress warnings
2019-06-30 11:41:10 +09:00
Nobuyoshi Nakada
45ba027d08
Removed unused variables
2019-06-30 08:45:01 +09:00
Nobuyoshi Nakada
792d1deb94
Escape control codes in regexp warning message
2019-06-29 19:07:25 +09:00
Nobuyoshi Nakada
27723b699b
Should not warn massign parameters as unused
2019-06-29 18:45:24 +09:00
Nobuyoshi Nakada
a17fba6989
Rmove old TestTimeTZ::TZ#abbr attribute
2019-06-29 17:55:22 +09:00
Nobuyoshi Nakada
7ba14b029c
Add max option to TestProtocol#create_mockio
...
* test/net/protocol/test_protocol.rb (TestProtocol#create_mockio):
max option to limit maximum writable size at once, and unify
mock method in test_write0_multibyte.
2019-06-29 17:52:57 +09:00
Nobuyoshi Nakada
2f6cc15cdb
Fixed String#grapheme_clusters with wide encodings
...
* string.c (get_reg_grapheme_cluster): make regexp from properly
encoded sources fro wide-char encodings. [Bug #15965 ]
* regparse.c (node_extended_grapheme_cluster): suppress false
duplicated range warning for the time being.
2019-06-29 10:10:17 +09:00
Nobuyoshi Nakada
8aecc90974
Hoisted out WIDE_ENCODINGS
2019-06-29 10:02:04 +09:00
Nobuyoshi Nakada
ede056909b
Set file name and line number
2019-06-29 01:31:52 +09:00