Commit graph

8794 commits

Author SHA1 Message Date
Nobuyoshi Nakada
cfa6a892d0
Redirect to IO::NULL for the portability 2023-05-05 18:52:36 +09:00
Nobuyoshi Nakada
409a13e9ea [ruby/stringio] Update write-barrier at copying
http://ci.rvm.jp/results/trunk-asserts@ruby-sp2-docker/4552803

```
verify_internal_consistency_reachable_i: WB miss (O->Y) 0x00007f752ddd5550 [3LM    ] strio (StringIO)strio -> 0x00007f752d19b7d0 [0      ] T_STRING (String) len: 8, capa: 15 "to_strio"
<internal:/tmp/ruby/src/trunk-asserts/lib/rubygems/core_ext/kernel_require.rb>:53: [BUG] gc_verify_internal_consistency: found internal inconsistency.
```

2e8ab43cba
2023-05-03 05:38:27 +00:00
Akinori MUSHA
85ed226cca [ruby/syslog] Improve the version extraction
34da65a002
2023-04-25 01:51:26 +00:00
Akinori MUSHA
a66c41d600 [ruby/syslog] Raise required_ruby_version
5289373016
2023-04-25 01:51:25 +00:00
Hiroshi SHIBATA
117fc8e72d [ruby/syslog] Expose Syslog::VERSION
ff5d72fcb9
2023-04-25 01:51:24 +00:00
Hiroshi SHIBATA
b9b43a1020 [ruby/win32ole] Reuse WIN32OLE_VERSION for gem version
bff3ea8b0b
2023-04-21 04:46:10 +00:00
Hiroshi SHIBATA
9702a8142b [ruby/fcntl] Expose Fcntl::VERSION
cb8e414e9f
2023-04-21 04:21:05 +00:00
Sutou Kouhei
67743d5823 [ruby/stringio] Development of 3.0.7 started.
5d39880f70
2023-04-14 06:38:51 +00:00
Hiroshi SHIBATA
3733ee835b [ruby/readline-ext] Expose Readline::GEM_VERSION
70aa84b80e
2023-04-14 03:43:46 +00:00
Hiroshi SHIBATA
283c190374 [ruby/nkf] Expose NKF::GEM_VERSION
0d0fb3a162
2023-04-14 03:43:17 +00:00
Hiroshi SHIBATA
8a06f1a69f [ruby/pathname] Expose Pathname::VERSION
2b0b1a82ee
2023-04-14 12:42:36 +09:00
HoNooD
671cfc2000 [ruby/bigdecimal] fix: typo in document comments of f_BigDecimal function
13abe1fd78
2023-04-08 18:54:01 +00:00
Nobuyoshi Nakada
8ec95c6074 [ruby/bigdecimal] Remove set but unused variable
This `prec` has not been used since 1f5c46dbdd.

08a0ad563d
2023-04-08 18:53:28 +00:00
Nobuyoshi Nakada
f99af43980 [Bug#19161] Detect thread local storage specifier
Checking by `__STDC_VERSION__` is unreliable because old gcc 4.8
supports `-std=gnu11` option but does not implement `_Thread_local`.
Check the implementation directly instead.
2023-04-07 13:42:48 +09:00
Nobuyoshi Nakada
75a2dff0e0 [ruby/openssl] Register global variables before assignment
98099d3796
2023-04-07 12:09:08 +09:00
Matt Valentine-House
2a34bcaa10 Update VPATH for socket, & dependencies
The socket extensions rubysocket.h pulls in the "private" include/gc.h,
which now depends on vm_core.h. vm_core.h pulls in id.h

when tool/update-deps generates the dependencies for the makefiles, it
generates the line for id.h to be based on VPATH, which is configured in
the extconf.rb for each of the extensions. By default VPATH does not
include the actual source directory of the current Ruby so the
dependency fails to resolve and linking fails.

We need to append the topdir and top_srcdir to VPATH to have the
dependancy picked up correctly (and I believe we need both of these to
cope with in-tree and out-of-tree builds).

I copied this from the approach taken in
https://github.com/ruby/ruby/blob/master/ext/objspace/extconf.rb#L3
2023-04-06 11:07:16 +01:00
Peter Zhu
1da2e7fca3
[Feature #19579] Remove !USE_RVARGC code (#7655)
Remove !USE_RVARGC code

[Feature #19579]

The Variable Width Allocation feature was turned on by default in Ruby
3.2. Since then, we haven't received bug reports or backports to the
non-Variable Width Allocation code paths, so we assume that nobody is
using it. We also don't plan on maintaining the non-Variable Width
Allocation code, so we are going to remove it.
2023-04-04 17:30:06 -04:00
Hiroshi SHIBATA
9b7a7e9cef [ruby/pathname] Remove taint/untaint methods because they should be removed since Ruby 3.2 released.
Fixes https://github.com/ruby/pathname/pull/28

c52fd3a835
2023-03-27 07:21:52 +00:00
Nobuyoshi Nakada
72811deaa8
MSWin: Use MESSAGE_BEGIN/MESSAGE_END instead of bare echo
To strip enclosing double quotes.
2023-03-02 19:18:13 +09:00
Matt Valentine-House
5e4b80177e Update the depend files 2023-02-28 09:09:00 -08:00
Jean Boussier
71dae78b89 [ruby/stringio] Implement write barrier on StringIO
It only has a single reference set in 3 places which
makes it fairly easy to implement.

009896b973
2023-02-28 03:07:10 +00:00
Matt Valentine-House
f38c6552f9 Remove intern/gc.h from Make deps 2023-02-27 10:11:56 -08:00
Hiroshi SHIBATA
db0a4c8923 Prefer to use File.foreach instead of IO.foreach 2023-02-27 18:49:18 +09:00
Hiroshi SHIBATA
d063ed12af Prefer to use File.binwrite instead of IO.binwrite 2023-02-27 18:49:18 +09:00
Hiroshi SHIBATA
6dfdc7b28e Prefer to use File.binread instead of IO.binread 2023-02-27 18:49:18 +09:00
BurdetteLamar
d3ee9e590c [ruby/stringio] Remove (newly unneeded) remarks about aliases
60bb320477
2023-02-25 08:38:19 +00:00
Nobuyoshi Nakada
0cde887eb9 [ruby/bigdecimal] Bump up to 3.1.4
ruby/bigdecimal#187 has changed a behavior and ruby/spec also needed a
follow up at 0d8ef62fc2.
However, because bigdecimal is a separate gem and can be updated in
older versions of ruby, `RUBY_VERSION` is not appropriate for this
guard.  That means it needs bumped up `BigDecimal::VERSION`.

3a2a7a9353
2023-02-21 15:35:40 +00:00
Benoit Daloze
7b768e4335 [ruby/bigdecimal] Move RB_GC_GUARD() at the end, like in BigMath_s_exp()
b66ef9fbb5
2023-02-21 14:24:13 +00:00
Benoit Daloze
5077cc2be6 [ruby/bigdecimal] Avoid RB_GC_GUARD(a) = b in bigdecimal
* This is not supported on TruffleRuby, which requires the value to be
  set before RB_GC_GUARD() is called.
* See https://github.com/oracle/truffleruby/pull/2879

7b2957922f
2023-02-21 14:24:12 +00:00
Charles Oliver Nutter
b572f2436c
[ruby/openssl] Stub gemspec for JRuby
JRuby has its own implementation of the `openssl` library in
jruby-openssl. The simplest way for us to allow users to set
openssl as a gem dependency is to ship a stub gem that just
depends on jruby-openssl. This patch adds that to the gemspec.
Additional work may be required to fit this stub gem into the test
and release process.

See #20 for more details.

74ccaa5e18
2023-02-21 19:50:49 +09:00
Sutou Kouhei
18e840ac60 [ruby/strscan] Bump version
681cde0f27
2023-02-21 19:31:36 +09:00
OKURA Masafumi
a44f5ab089 [ruby/strscan] Mention return value of rest? in the doc
(https://github.com/ruby/strscan/pull/49)

The doc of `rest?` was unclear about return value. This commit adds the
return value to the doc.
2023-02-21 19:31:35 +09:00
Nobuyoshi Nakada
d13879f862 [ruby/bigdecimal] Read version from bigdecimal.c
The dependency of extconf.h on bigdecimal.gemspec does not make sense
as far as no rule is defined for it.  Also, the relationship between
extension library and gemspec file is various in default gems, and
does not work well.

7f99b28552
2023-02-21 09:50:02 +00:00
Burdette Lamar
3d53827130 [ruby/date] Removed (newly unneeded) alias remarks
(https://github.com/ruby/date/pull/88)

cfa7e9868b
2023-02-19 22:24:39 +00:00
zverok
e1b447a323 [DOC] Improve ObjectSpace#dump_XXX method docs
* remove false call-seq (output from Ruby parsing is cleaner)
* explain output: argument in plain words
* change parameter name in docs of #dump_shapes (typo)
2023-02-19 22:32:52 +02:00
Nobuyoshi Nakada
ba1b9d3104 [ruby/bigdecimal] Fix the license name [ci skip]
```
$ gem build bigdecimal.gemspec
WARNING:  license value 'BSD-2-clause' is invalid.  Use a license identifier from
http://spdx.org/licenses or 'Nonstandard' for a nonstandard license.
Did you mean 'BSD-2-Clause'?
WARNING:  See https://guides.rubygems.org/specification-reference/ for help
```

36b77a2d2f
2023-02-19 09:58:31 +00:00
Charles Oliver Nutter
becec0001c [ruby/bigdecimal] Stub out extension build on JRuby
JRuby currently ships its own internal bigdecimal extension as
part of the core libraries. In order for users to be able to add
bigdecimal to their Gemfile or gem dependencies, we need to stub
out the C extension and just load the extension shipped with
JRuby.

In the future we will try to move our BigDecimal implementation
into the gem, but for now this is the simplest way to make it
installable on JRuby.

See #169

829956c643
2023-02-17 17:52:48 +00:00
Maciej Rzasa
36e3d46d35 [ruby/bigdecimal] Handle correctly #remainder with infinity. Fixes
https://github.com/ruby/bigdecimal/pull/187

4b8572d452
2023-02-17 17:46:27 +00:00
Jean Boussier
7413079dae Encapsulate RCLASS_ATTACHED_OBJECT
Right now the attached object is stored as an instance variable
and all the call sites that either get or set it have to know how it's
stored.

It's preferable to hide this implementation detail behind accessors
so that it is easier to change how it's stored.
2023-02-15 15:24:22 +01:00
Matt Valentine-House
72aba64fff Merge gc.h and internal/gc.h
[Feature #19425]
2023-02-09 10:32:29 -05:00
Nobuyoshi Nakada
899ea35035
Extract include/ruby/internal/attr/packed_struct.h
Split `PACKED_STRUCT` and `PACKED_STRUCT_UNALIGNED` macros into the
macros bellow:
* `RBIMPL_ATTR_PACKED_STRUCT_BEGIN`
* `RBIMPL_ATTR_PACKED_STRUCT_END`
* `RBIMPL_ATTR_PACKED_STRUCT_UNALIGNED_BEGIN`
* `RBIMPL_ATTR_PACKED_STRUCT_UNALIGNED_END`
2023-02-08 12:34:13 +09:00
Charles Oliver Nutter
a66bc448a4 [ruby/psych] Bump version to 5.1 for release
This version primarily updates the JRuby extension to use
SnakeYAML Engine, a newer version of the SnakeYAML library, which
also updates YAML support to 1.2. The JRuby extension now also
exposes settings for the parser.

6f2b16b343
2023-02-07 12:25:44 +00:00
Nobuyoshi Nakada
cbd5de4f88 [ruby/stringio] Development of 3.0.6 started.
a7561f447b
2023-02-03 07:49:31 +00:00
Nobuyoshi Nakada
89d9547800 [ruby/stringio] Revert "bump up to 3.0.6" [ci skip]
This reverts commit 325933500b.
It is bumped to 3.0.5 in advance but not released yet.

af67c36693
2023-02-02 12:44:53 +00:00
Nobuyoshi Nakada
8087ba736e [ruby/stringio] bump up to 3.0.6
325933500b
2023-02-02 04:44:38 +00:00
Nobuyoshi Nakada
fad48fefe1 [Bug #19399] Parsing invalid heredoc inside block parameter
Although this is of course invalid as Ruby code, allow to just parse
and tokenize.
2023-02-02 12:20:10 +09:00
Peter Zhu
aa222b56fa [ruby/bigdecimal] Make BigDecimal WB protected
BigDecimal has no references, so it is WB protected.

29c61c90e8
2023-02-01 15:59:11 +00:00
Mau Magnaguagno
5b67c15cd8
[ruby/openssl] [DOC] Remove repeated example from Digest
5a36cc3cb2
2023-01-31 13:14:06 +09:00
Charles Oliver Nutter
0ee819b71d
Initial move to SnakeYAML Engine
See jruby/jruby#7570 for some of the justification for this move. We only
require the parser from SnakeYAML, but in the original form it is
encumbered with Java object serialization code that keeps getting
flagged as a CVE risk. We disagree with the assessment, at least
as it pertains to JRuby (we do not use the code in question) but
our inclusion of the library continues to get flagged by auditing
tools.

This commit starts the process of moving to the successor library,
SnakeYAML Engine. The parser API is largely unchanged, except as
seen in this commit. No Java exceptions are thrown, but a number
of Psych tests fail (possibly due to Engine being YAML 1.2 only).
2023-01-31 13:14:05 +09:00
Nobuyoshi Nakada
4bc343b436 Extract check for RSTRING_SOCKLEN 2023-01-30 21:55:37 +09:00