Commit graph

7577 commits

Author SHA1 Message Date
Kazuhiro NISHIYAMA
946cd6c534
Use https instead of http 2020-07-28 19:51:54 +09:00
Simon Perepelitsa
09e9f7cf7a [DOC] Clarify ObjectSpace return values are in bytes [ci skip] 2020-07-28 12:13:40 +09:00
Jean Boussier
6a0cb1d649 Avoid allocating a string when dumping an anonymous module or class 2020-07-23 10:52:30 +09:00
Nobuyoshi Nakada
16daee1c75 [ruby/stringio] Bump version to 0.1.3
376516cd2d
2020-07-20 14:59:19 +09:00
Nobuyoshi Nakada
ddb2acbba6 [ruby/stringio] No compatibility check in US-ASCII case
59df1c8293
2020-07-20 14:59:19 +09:00
Nobuyoshi Nakada
a7c67fc6da [ruby/stringio] Removed wrong UNREACHABLE
f528538d10
2020-07-20 14:59:19 +09:00
Nobuyoshi Nakada
574871781b [ruby/stringio] Bump version to 0.1.2
8cbe3f7397
2020-07-20 14:59:19 +09:00
Nobuyoshi Nakada
6ff9604f85 [ruby/stringio] Raise an error if encoding conversion not succeeded
As `rb_str_conv_enc()` returns the argument string object itself
unchanged when any conversion failed, check the incompatibility in
that case.

Fixes https://github.com/ruby/stringio/issues/13

ede6bdcc71
2020-07-20 14:59:19 +09:00
Nobuyoshi Nakada
d2bf6133f6
Remove trailing spaces [ci skip] 2020-07-20 13:34:16 +09:00
Masataka Pocke Kuwabara
8d2333019a Fix MonitorMixin when the super's initialize has kwargs 2020-07-17 16:37:18 -07:00
Alan Wu
cbf52087a2 Fix missing imemo cases in objspace_dump by refactoring
imemo_callcache and imemo_callinfo were not handled by the `objspace`
module and were showing up as "unknown" in the dump. Extract the code for
naming imemos and use that in both the GC and the `objspace` module.
2020-07-10 22:42:35 -04:00
Kenta Murata
efe851a0df
[ruby/bigdecimal] Version 2.0.1
3fa4f2ac67
2020-07-06 01:15:47 +09:00
Kenta Murata
6a826eb4b0
[ruby/bigdecimal] Return US-ASCII string from BigDecimal#to_s
Fixes #159

57ee92e700
2020-07-06 01:15:47 +09:00
Kenta Murata
e794d96ca4
[ruby/bigdecimal] Drop Ruby 2.3 support
79a819d205
2020-07-06 01:15:47 +09:00
Kenta Murata
40b82afe6a
[ruby/bigdecimal] Support Ruby < 2.6
61ec452599
2020-07-06 01:15:46 +09:00
Kenta Murata
03a33603c6
[ruby/bigdecimal] Add Complex#to_d
97e794ac97
2020-07-06 01:15:46 +09:00
Jeremy Evans
d36b197d7c
[ruby/bigdecimal] Remove definition of BigDecimal#initialize_copy
This leaves the default definition, which will raise FrozenError.

05e843d838
2020-07-06 01:15:46 +09:00
Kenta Murata
f00efef30a
[ruby/bigdecimal] Support a Complex in Kernel.BigDecimal()
00795cb01f
2020-07-06 01:15:46 +09:00
Jeremy Evans
ceb9d516c6
[ruby/bigdecimal] Undef BigDecimal#initialize_copy
Both BigDecimal#clone and BigDecimal#dup return self, there is no
reason to have initialize_copy exposed as a Ruby method.

The same is true for initialize_clone and initialize_dup.

aaf237fa9e
2020-07-06 01:15:45 +09:00
Nobuyoshi Nakada
d69510b6cd
Removed ext/bigdecimal/util/depend unused since dd0c75fdc2 2020-07-06 01:15:23 +09:00
Hiroshi SHIBATA
0aac138e0b
Merge json-2.3.1 from flori/json 2020-07-01 18:50:39 +09:00
Marc-Andre Lafortune
26041da2fb
[flori/json] Typo fix
26c1769969
2020-07-01 18:47:51 +09:00
BurdetteLamar
d69b55ac05
[flori/json] Added :call-seq: to RDOc for some methods
ee5b6a74e9
2020-07-01 18:47:51 +09:00
Watson
cb3e62511c
[flori/json] Use frozen string for hash key
When use non-frozen string for hash key with `rb_hash_aset()`, it will duplicate and freeze it internally.
To avoid duplicate and freeze, this patch will give a frozen string in `rb_hash_aset()`.

```
Warming up --------------------------------------
                json    14.000  i/100ms
Calculating -------------------------------------
                json    148.844  (± 1.3%) i/s -    756.000  in   5.079969s
```

```
Warming up --------------------------------------
                json    16.000  i/100ms
Calculating -------------------------------------
                json    165.608  (± 1.8%) i/s -    832.000  in   5.025367s
```

```
require 'json'
require 'securerandom'
require 'benchmark/ips'

obj = []

1000.times do |i|
  obj << {
    "id": i,
    "uuid": SecureRandom.uuid,
    "created_at": Time.now
  }
end

json = obj.to_json

Benchmark.ips do |x|
  x.report "json" do |iter|
    count = 0
    while count < iter
      JSON.parse(json)
      count += 1
    end
  end
end
```

18292c0c1d
2020-07-01 18:47:51 +09:00
BurdetteLamar
7d8ce96de6
[flori/json] RDoc enhancements
ada48f0236
2020-07-01 18:47:51 +09:00
BurdetteLamar
be6447381c
[flori/json] RDoc enhancements
470d909c0d
2020-07-01 18:47:51 +09:00
BurdetteLamar
99980b3034
[flori/json] RDoc enhancements
7bee2c7c13
2020-07-01 18:47:51 +09:00
BurdetteLamar
4689fd5f99
[flori/json] Rdoc enhancements
e7e3732130
2020-07-01 18:47:50 +09:00
Nobuyoshi Nakada
48fb6299c6
[ruby/fiddle] support for very old libffi
Define `Fiddle::TYPE_VARIADIC` only when `ffi_prep_cif_var` is
available, otherwise skip the test for it.
2020-06-28 10:40:31 +09:00
Nobuyoshi Nakada
c405a8d37a
[ruby/fiddle] try bundled libffi by default
If no installed libffi found, use bundled libffi unless explicitly
`--disable-bundled-libffi` option is given.
2020-06-28 01:03:21 +09:00
Sutou Kouhei
f2bcdc7283
[ruby/fiddle] Support MSWIN (#43)
f16e7ff6e0
2020-06-27 23:54:09 +09:00
Sutou Kouhei
6429b6d973
[ruby/fiddle] Add missing include
4ca61efcd7
2020-06-27 23:54:08 +09:00
Sutou Kouhei
ae18220f99
[ruby/fiddle] Add support for variadic arguments
GitHub: fix GH-39

Reported by kojix2. Thanks!!!

6c4cb904dc
2020-06-27 23:54:08 +09:00
Sutou Kouhei
9f740acaf9
[ruby/fiddle] Use meaningful variable name
2cac24b7c8
2020-06-27 23:54:08 +09:00
Sutou Kouhei
50fbd00e76
[ruby/fiddle] Use "do { } while (0)" to ensure requiring ";"
2155ae5979
2020-06-27 23:54:08 +09:00
Nobuyoshi Nakada
4949df498a
[ruby/fiddle] Fixed typos
a09e66adf4
6cab9b45d6
ab72b19bed
2020-06-26 17:05:27 +09:00
Nobuyoshi Nakada
9a78e24f7d
Removed nonsense rubygems_version in input gemspec files
As it is ignored and set at building packages automatically, it is
just nonsense to set in gemspec file for input.
2020-06-25 15:44:56 +09:00
noraj
4eff8a662a
[flori/json] add metadata
9f430a7bba
2020-06-25 15:32:41 +09:00
Hiroshi SHIBATA
1b076ca30d
[flori/json] Gem::Specification#date is set automatically by RubyGems.org.
1920653013
2020-06-25 15:32:41 +09:00
Hiroshi SHIBATA
4dbb10f29f
[flori/json] keyword argument is provided after Ruby 2.0+
78ec5e2bd3
2020-06-25 15:32:40 +09:00
Hiroshi SHIBATA
078e94106d
[ruby/psych] Fixup 05d7e818a6abe3ee1c56b6be92f086647d73141c
4e7794fc2c
2020-06-23 15:26:29 +09:00
Hiroshi SHIBATA
7cdfc2b5fc
[ruby/psych] Bump version strings for header file
68da645c7e
2020-06-23 15:26:29 +09:00
Hiroshi SHIBATA
70a4599869
[ruby/psych] Bump libyaml version to 0.2.5
39996192cc
2020-06-23 15:26:29 +09:00
Jean Boussier
666c077691
[ruby/psych] Fix anchor lookup with symbolized names
ef74fc01e2
2020-06-23 15:26:29 +09:00
Nobuyoshi Nakada
e9adc2f420
Match the output without encoding for localized compilers 2020-06-23 15:05:44 +09:00
Nobuyoshi Nakada
956d187223
[ruby/date] [DOC] Mentioned alternative strptime methods
5f4ac92947
2020-06-21 16:16:15 +09:00
Nobuyoshi Nakada
67e544cbe1
[ruby/date] [DOC] Emphasized that parse methods are not validators
81a057db11
2020-06-21 16:16:15 +09:00
Hiroshi SHIBATA
b68ddcf30c
[ruby/date] Bump version to 3.0.1
47cca1b76b
2020-06-20 18:35:03 +09:00
Nobuyoshi Nakada
97e8b7d098
[ruby/date] Promote simple date to complex date to load fractional date (Fixes #20)
e022e8b3ce
2020-06-20 18:35:03 +09:00
Jeremy Evans
ad156f7e2c
[ruby/date] Fix cannot load complex into simple error when loading marshal dump (Fixes #20)
This problem exists because Marshal.load calls Date.allocate, which
uses a SimpleDateData.  There doesn't seem to be any support for
taking an existing Date instance and converting it from SimpleDateData
to ComplexDateData.  Work around this issue by making Date.allocate
use a ComplexDateData.  This causes problems in Date#initialize,
so remove the Date#initialize method (keeping the date_initialize
function, used internally for Date.civil). Alias Date.new to
Date.civil, since they do the same thing.

6bb8d8fa0f
2020-06-20 18:35:03 +09:00