json 2.7.2 → 2.8.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/BSDL +22 -0
- data/CHANGES.md +73 -17
- data/LEGAL +60 -0
- data/README.md +15 -236
- data/ext/json/ext/fbuffer/fbuffer.h +76 -79
- data/ext/json/ext/generator/extconf.rb +8 -2
- data/ext/json/ext/generator/generator.c +776 -816
- data/ext/json/ext/parser/extconf.rb +7 -27
- data/ext/json/ext/parser/parser.c +1697 -670
- data/ext/json/ext/parser/parser.rl +832 -338
- data/json.gemspec +45 -49
- data/lib/json/add/bigdecimal.rb +2 -2
- data/lib/json/add/complex.rb +1 -1
- data/lib/json/add/core.rb +1 -1
- data/lib/json/add/date.rb +1 -1
- data/lib/json/add/date_time.rb +1 -1
- data/lib/json/add/exception.rb +1 -1
- data/lib/json/add/ostruct.rb +1 -1
- data/lib/json/add/range.rb +1 -1
- data/lib/json/add/rational.rb +1 -1
- data/lib/json/add/regexp.rb +1 -1
- data/lib/json/add/struct.rb +1 -1
- data/lib/json/add/symbol.rb +1 -2
- data/lib/json/add/time.rb +3 -10
- data/lib/json/common.rb +273 -95
- data/lib/json/ext/generator/state.rb +105 -0
- data/lib/json/ext.rb +13 -5
- data/lib/json/generic_object.rb +1 -1
- data/lib/json/{pure → truffle_ruby}/generator.rb +228 -120
- data/lib/json/version.rb +3 -7
- data/lib/json.rb +16 -21
- metadata +19 -21
- data/ext/json/ext/generator/depend +0 -1
- data/ext/json/ext/generator/generator.h +0 -177
- data/ext/json/ext/parser/depend +0 -1
- data/ext/json/ext/parser/parser.h +0 -96
- data/ext/json/extconf.rb +0 -3
- data/lib/json/pure/parser.rb +0 -337
- data/lib/json/pure.rb +0 -15
- /data/{LICENSE → COPYING} +0 -0
@@ -1,103 +1,105 @@
|
|
1
|
-
#frozen_string_literal:
|
1
|
+
# frozen_string_literal: true
|
2
2
|
module JSON
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
3
|
+
module TruffleRuby
|
4
|
+
module Generator
|
5
|
+
MAP = {
|
6
|
+
"\x0" => '\u0000',
|
7
|
+
"\x1" => '\u0001',
|
8
|
+
"\x2" => '\u0002',
|
9
|
+
"\x3" => '\u0003',
|
10
|
+
"\x4" => '\u0004',
|
11
|
+
"\x5" => '\u0005',
|
12
|
+
"\x6" => '\u0006',
|
13
|
+
"\x7" => '\u0007',
|
14
|
+
"\b" => '\b',
|
15
|
+
"\t" => '\t',
|
16
|
+
"\n" => '\n',
|
17
|
+
"\xb" => '\u000b',
|
18
|
+
"\f" => '\f',
|
19
|
+
"\r" => '\r',
|
20
|
+
"\xe" => '\u000e',
|
21
|
+
"\xf" => '\u000f',
|
22
|
+
"\x10" => '\u0010',
|
23
|
+
"\x11" => '\u0011',
|
24
|
+
"\x12" => '\u0012',
|
25
|
+
"\x13" => '\u0013',
|
26
|
+
"\x14" => '\u0014',
|
27
|
+
"\x15" => '\u0015',
|
28
|
+
"\x16" => '\u0016',
|
29
|
+
"\x17" => '\u0017',
|
30
|
+
"\x18" => '\u0018',
|
31
|
+
"\x19" => '\u0019',
|
32
|
+
"\x1a" => '\u001a',
|
33
|
+
"\x1b" => '\u001b',
|
34
|
+
"\x1c" => '\u001c',
|
35
|
+
"\x1d" => '\u001d',
|
36
|
+
"\x1e" => '\u001e',
|
37
|
+
"\x1f" => '\u001f',
|
38
|
+
'"' => '\"',
|
39
|
+
'\\' => '\\\\',
|
40
|
+
}.freeze # :nodoc:
|
41
|
+
|
42
|
+
ESCAPE_PATTERN = /[\/"\\\x0-\x1f]/n # :nodoc:
|
43
|
+
|
44
|
+
SCRIPT_SAFE_MAP = MAP.merge(
|
45
|
+
'/' => '\\/',
|
46
|
+
"\u2028".b => '\u2028',
|
47
|
+
"\u2029".b => '\u2029',
|
48
|
+
).freeze
|
49
|
+
|
50
|
+
SCRIPT_SAFE_ESCAPE_PATTERN = Regexp.union(ESCAPE_PATTERN, "\u2028".b, "\u2029".b)
|
51
|
+
|
52
|
+
# Convert a UTF8 encoded Ruby string _string_ to a JSON string, encoded with
|
53
|
+
# UTF16 big endian characters as \u????, and return it.
|
54
|
+
def utf8_to_json(string, script_safe = false) # :nodoc:
|
55
|
+
string = string.b
|
56
|
+
if script_safe
|
57
|
+
string.gsub!(SCRIPT_SAFE_ESCAPE_PATTERN) { SCRIPT_SAFE_MAP[$&] || $& }
|
58
|
+
else
|
59
|
+
string.gsub!(ESCAPE_PATTERN) { MAP[$&] || $& }
|
60
|
+
end
|
61
|
+
string.force_encoding(::Encoding::UTF_8)
|
62
|
+
string
|
63
|
+
end
|
63
64
|
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
end
|
65
|
+
def utf8_to_json_ascii(string, script_safe = false) # :nodoc:
|
66
|
+
string = string.b
|
67
|
+
map = script_safe ? SCRIPT_SAFE_MAP : MAP
|
68
|
+
string.gsub!(/[\/"\\\x0-\x1f]/n) { map[$&] || $& }
|
69
|
+
string.gsub!(/(
|
70
|
+
(?:
|
71
|
+
[\xc2-\xdf][\x80-\xbf] |
|
72
|
+
[\xe0-\xef][\x80-\xbf]{2} |
|
73
|
+
[\xf0-\xf4][\x80-\xbf]{3}
|
74
|
+
)+ |
|
75
|
+
[\x80-\xc1\xf5-\xff] # invalid
|
76
|
+
)/nx) { |c|
|
77
|
+
c.size == 1 and raise GeneratorError, "invalid utf8 byte: '#{c}'"
|
78
|
+
s = c.encode(::Encoding::UTF_16BE, ::Encoding::UTF_8).unpack('H*')[0]
|
79
|
+
s.force_encoding(::Encoding::BINARY)
|
80
|
+
s.gsub!(/.{4}/n, '\\\\u\&')
|
81
|
+
s.force_encoding(::Encoding::UTF_8)
|
82
|
+
}
|
83
|
+
string.force_encoding(::Encoding::UTF_8)
|
84
|
+
string
|
85
|
+
rescue => e
|
86
|
+
raise GeneratorError.wrap(e)
|
87
|
+
end
|
88
88
|
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
89
|
+
def valid_utf8?(string)
|
90
|
+
encoding = string.encoding
|
91
|
+
(encoding == Encoding::UTF_8 || encoding == Encoding::ASCII) &&
|
92
|
+
string.valid_encoding?
|
93
|
+
end
|
94
|
+
module_function :utf8_to_json, :utf8_to_json_ascii, :valid_utf8?
|
95
95
|
|
96
|
-
module Pure
|
97
|
-
module Generator
|
98
96
|
# This class is used to create State instances, that are use to hold data
|
99
97
|
# while generating a JSON text from a Ruby data structure.
|
100
98
|
class State
|
99
|
+
def self.generate(obj, opts = nil)
|
100
|
+
new(opts).generate(obj)
|
101
|
+
end
|
102
|
+
|
101
103
|
# Creates a State object from _opts_, which ought to be Hash to create
|
102
104
|
# a new State instance configured by _opts_, something else to create
|
103
105
|
# an unconfigured instance. If _opts_ is a State object, it is just
|
@@ -132,7 +134,7 @@ module JSON
|
|
132
134
|
# * *allow_nan*: true if NaN, Infinity, and -Infinity should be
|
133
135
|
# generated, otherwise an exception is thrown, if these values are
|
134
136
|
# encountered. This options defaults to false.
|
135
|
-
def initialize(opts =
|
137
|
+
def initialize(opts = nil)
|
136
138
|
@indent = ''
|
137
139
|
@space = ''
|
138
140
|
@space_before = ''
|
@@ -140,10 +142,12 @@ module JSON
|
|
140
142
|
@array_nl = ''
|
141
143
|
@allow_nan = false
|
142
144
|
@ascii_only = false
|
143
|
-
@
|
144
|
-
@strict = false
|
145
|
+
@depth = 0
|
145
146
|
@buffer_initial_length = 1024
|
146
|
-
|
147
|
+
@script_safe = false
|
148
|
+
@strict = false
|
149
|
+
@max_nesting = 100
|
150
|
+
configure(opts) if opts
|
147
151
|
end
|
148
152
|
|
149
153
|
# This string is used to indent levels in the JSON text.
|
@@ -219,7 +223,9 @@ module JSON
|
|
219
223
|
@script_safe
|
220
224
|
end
|
221
225
|
|
222
|
-
# Returns true, if
|
226
|
+
# Returns true, if strict mode is enabled. Otherwise returns false.
|
227
|
+
# Strict mode only allow serializing JSON native types: Hash, Array,
|
228
|
+
# String, Integer, Float, true, false and nil.
|
223
229
|
def strict?
|
224
230
|
@strict
|
225
231
|
end
|
@@ -237,13 +243,15 @@ module JSON
|
|
237
243
|
opts.each do |key, value|
|
238
244
|
instance_variable_set "@#{key}", value
|
239
245
|
end
|
240
|
-
|
241
|
-
|
242
|
-
@
|
243
|
-
@
|
244
|
-
@
|
245
|
-
@
|
246
|
-
@
|
246
|
+
|
247
|
+
# NOTE: If adding new instance variables here, check whether #generate should check them for #generate_json
|
248
|
+
@indent = opts[:indent] || '' if opts.key?(:indent)
|
249
|
+
@space = opts[:space] || '' if opts.key?(:space)
|
250
|
+
@space_before = opts[:space_before] || '' if opts.key?(:space_before)
|
251
|
+
@object_nl = opts[:object_nl] || '' if opts.key?(:object_nl)
|
252
|
+
@array_nl = opts[:array_nl] || '' if opts.key?(:array_nl)
|
253
|
+
@allow_nan = !!opts[:allow_nan] if opts.key?(:allow_nan)
|
254
|
+
@ascii_only = opts[:ascii_only] if opts.key?(:ascii_only)
|
247
255
|
@depth = opts[:depth] || 0
|
248
256
|
@buffer_initial_length ||= opts[:buffer_initial_length]
|
249
257
|
|
@@ -286,12 +294,83 @@ module JSON
|
|
286
294
|
# created this method raises a
|
287
295
|
# GeneratorError exception.
|
288
296
|
def generate(obj)
|
289
|
-
|
290
|
-
|
297
|
+
if @indent.empty? and @space.empty? and @space_before.empty? and @object_nl.empty? and @array_nl.empty? and
|
298
|
+
!@ascii_only and !@script_safe and @max_nesting == 0 and !@strict
|
299
|
+
result = generate_json(obj, ''.dup)
|
300
|
+
else
|
301
|
+
result = obj.to_json(self)
|
302
|
+
end
|
303
|
+
JSON::TruffleRuby::Generator.valid_utf8?(result) or raise GeneratorError,
|
291
304
|
"source sequence #{result.inspect} is illegal/malformed utf-8"
|
292
305
|
result
|
293
306
|
end
|
294
307
|
|
308
|
+
# Handles @allow_nan, @buffer_initial_length, other ivars must be the default value (see above)
|
309
|
+
private def generate_json(obj, buf)
|
310
|
+
case obj
|
311
|
+
when Hash
|
312
|
+
buf << '{'
|
313
|
+
first = true
|
314
|
+
obj.each_pair do |k,v|
|
315
|
+
buf << ',' unless first
|
316
|
+
|
317
|
+
key_str = k.to_s
|
318
|
+
if key_str.class == String
|
319
|
+
fast_serialize_string(key_str, buf)
|
320
|
+
elsif key_str.is_a?(String)
|
321
|
+
generate_json(key_str, buf)
|
322
|
+
else
|
323
|
+
raise TypeError, "#{k.class}#to_s returns an instance of #{key_str.class}, expected a String"
|
324
|
+
end
|
325
|
+
|
326
|
+
buf << ':'
|
327
|
+
generate_json(v, buf)
|
328
|
+
first = false
|
329
|
+
end
|
330
|
+
buf << '}'
|
331
|
+
when Array
|
332
|
+
buf << '['
|
333
|
+
first = true
|
334
|
+
obj.each do |e|
|
335
|
+
buf << ',' unless first
|
336
|
+
generate_json(e, buf)
|
337
|
+
first = false
|
338
|
+
end
|
339
|
+
buf << ']'
|
340
|
+
when String
|
341
|
+
if obj.class == String
|
342
|
+
fast_serialize_string(obj, buf)
|
343
|
+
else
|
344
|
+
buf << obj.to_json(self)
|
345
|
+
end
|
346
|
+
when Integer
|
347
|
+
buf << obj.to_s
|
348
|
+
else
|
349
|
+
# Note: Float is handled this way since Float#to_s is slow anyway
|
350
|
+
buf << obj.to_json(self)
|
351
|
+
end
|
352
|
+
end
|
353
|
+
|
354
|
+
# Assumes !@ascii_only, !@script_safe
|
355
|
+
private def fast_serialize_string(string, buf) # :nodoc:
|
356
|
+
buf << '"'
|
357
|
+
unless string.encoding == ::Encoding::UTF_8
|
358
|
+
begin
|
359
|
+
string = string.encode(::Encoding::UTF_8)
|
360
|
+
rescue Encoding::UndefinedConversionError => error
|
361
|
+
raise GeneratorError, error.message
|
362
|
+
end
|
363
|
+
end
|
364
|
+
raise GeneratorError, "source sequence is illegal/malformed utf-8" unless string.valid_encoding?
|
365
|
+
|
366
|
+
if /["\\\x0-\x1f]/n.match?(string)
|
367
|
+
buf << string.gsub(/["\\\x0-\x1f]/n, MAP)
|
368
|
+
else
|
369
|
+
buf << string
|
370
|
+
end
|
371
|
+
buf << '"'
|
372
|
+
end
|
373
|
+
|
295
374
|
# Return the value returned by method +name+.
|
296
375
|
def [](name)
|
297
376
|
if respond_to?(name)
|
@@ -316,8 +395,8 @@ module JSON
|
|
316
395
|
# Converts this object to a string (calling #to_s), converts
|
317
396
|
# it to a JSON string, and returns the result. This is a fallback, if no
|
318
397
|
# special method #to_json was defined for some object.
|
319
|
-
def to_json(
|
320
|
-
if
|
398
|
+
def to_json(state = nil, *)
|
399
|
+
if state && State.from_state(state).strict?
|
321
400
|
raise GeneratorError, "#{self.class} not allowed in JSON"
|
322
401
|
else
|
323
402
|
to_s.to_json
|
@@ -345,16 +424,30 @@ module JSON
|
|
345
424
|
end
|
346
425
|
|
347
426
|
def json_transform(state)
|
348
|
-
delim = ",#{state.object_nl}"
|
349
|
-
result = "{#{state.object_nl}"
|
350
427
|
depth = state.depth += 1
|
428
|
+
|
429
|
+
if empty?
|
430
|
+
state.depth -= 1
|
431
|
+
return '{}'
|
432
|
+
end
|
433
|
+
|
434
|
+
delim = ",#{state.object_nl}"
|
435
|
+
result = +"{#{state.object_nl}"
|
351
436
|
first = true
|
352
437
|
indent = !state.object_nl.empty?
|
353
438
|
each { |key, value|
|
354
439
|
result << delim unless first
|
355
440
|
result << state.indent * depth if indent
|
356
|
-
|
357
|
-
|
441
|
+
|
442
|
+
key_str = key.to_s
|
443
|
+
if key_str.is_a?(String)
|
444
|
+
key_json = key_str.to_json(state)
|
445
|
+
else
|
446
|
+
raise TypeError, "#{key.class}#to_s returns an instance of #{key_str.class}, expected a String"
|
447
|
+
end
|
448
|
+
|
449
|
+
result = +"#{result}#{key_json}#{state.space_before}:#{state.space}"
|
450
|
+
if state.strict? && !(false == value || true == value || nil == value || String === value || Array === value || Hash === value || Integer === value || Float === value)
|
358
451
|
raise GeneratorError, "#{value.class} not allowed in JSON"
|
359
452
|
elsif value.respond_to?(:to_json)
|
360
453
|
result << value.to_json(state)
|
@@ -387,17 +480,27 @@ module JSON
|
|
387
480
|
private
|
388
481
|
|
389
482
|
def json_transform(state)
|
390
|
-
delim = ','
|
391
|
-
delim << state.array_nl
|
392
|
-
result = '['
|
393
|
-
result << state.array_nl
|
394
483
|
depth = state.depth += 1
|
484
|
+
|
485
|
+
if empty?
|
486
|
+
state.depth -= 1
|
487
|
+
return '[]'
|
488
|
+
end
|
489
|
+
|
490
|
+
result = '['.dup
|
491
|
+
if state.array_nl.empty?
|
492
|
+
delim = ","
|
493
|
+
else
|
494
|
+
result << state.array_nl
|
495
|
+
delim = ",#{state.array_nl}"
|
496
|
+
end
|
497
|
+
|
395
498
|
first = true
|
396
499
|
indent = !state.array_nl.empty?
|
397
500
|
each { |value|
|
398
501
|
result << delim unless first
|
399
502
|
result << state.indent * depth if indent
|
400
|
-
if state.strict?
|
503
|
+
if state.strict? && !(false == value || true == value || nil == value || String === value || Array === value || Hash === value || Integer === value || Float === value)
|
401
504
|
raise GeneratorError, "#{value.class} not allowed in JSON"
|
402
505
|
elsif value.respond_to?(:to_json)
|
403
506
|
result << value.to_json(state)
|
@@ -448,15 +551,20 @@ module JSON
|
|
448
551
|
def to_json(state = nil, *args)
|
449
552
|
state = State.from_state(state)
|
450
553
|
if encoding == ::Encoding::UTF_8
|
554
|
+
unless valid_encoding?
|
555
|
+
raise GeneratorError, "source sequence is illegal/malformed utf-8"
|
556
|
+
end
|
451
557
|
string = self
|
452
558
|
else
|
453
559
|
string = encode(::Encoding::UTF_8)
|
454
560
|
end
|
455
561
|
if state.ascii_only?
|
456
|
-
|
562
|
+
%("#{JSON::TruffleRuby::Generator.utf8_to_json_ascii(string, state.script_safe)}")
|
457
563
|
else
|
458
|
-
|
564
|
+
%("#{JSON::TruffleRuby::Generator.utf8_to_json(string, state.script_safe)}")
|
459
565
|
end
|
566
|
+
rescue Encoding::UndefinedConversionError => error
|
567
|
+
raise ::JSON::GeneratorError, error.message
|
460
568
|
end
|
461
569
|
|
462
570
|
# Module that holds the extending methods if, the String module is
|
data/lib/json/version.rb
CHANGED
@@ -1,9 +1,5 @@
|
|
1
|
-
# frozen_string_literal:
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
2
3
|
module JSON
|
3
|
-
|
4
|
-
VERSION = '2.7.2'
|
5
|
-
VERSION_ARRAY = VERSION.split(/\./).map { |x| x.to_i } # :nodoc:
|
6
|
-
VERSION_MAJOR = VERSION_ARRAY[0] # :nodoc:
|
7
|
-
VERSION_MINOR = VERSION_ARRAY[1] # :nodoc:
|
8
|
-
VERSION_BUILD = VERSION_ARRAY[2] # :nodoc:
|
4
|
+
VERSION = '2.8.2'
|
9
5
|
end
|
data/lib/json.rb
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
#frozen_string_literal:
|
1
|
+
# frozen_string_literal: true
|
2
2
|
require 'json/common'
|
3
3
|
|
4
4
|
##
|
@@ -378,13 +378,13 @@ require 'json/common'
|
|
378
378
|
# json1 = JSON.generate(ruby)
|
379
379
|
# ruby1 = JSON.parse(json1, create_additions: true)
|
380
380
|
# # Make a nice display.
|
381
|
-
# display =
|
382
|
-
#
|
383
|
-
#
|
384
|
-
#
|
385
|
-
#
|
386
|
-
#
|
387
|
-
#
|
381
|
+
# display = <<~EOT
|
382
|
+
# Generated JSON:
|
383
|
+
# Without addition: #{json0} (#{json0.class})
|
384
|
+
# With addition: #{json1} (#{json1.class})
|
385
|
+
# Parsed JSON:
|
386
|
+
# Without addition: #{ruby0.inspect} (#{ruby0.class})
|
387
|
+
# With addition: #{ruby1.inspect} (#{ruby1.class})
|
388
388
|
# EOT
|
389
389
|
# puts display
|
390
390
|
#
|
@@ -562,13 +562,13 @@ require 'json/common'
|
|
562
562
|
# json1 = JSON.generate(foo1)
|
563
563
|
# obj1 = JSON.parse(json1, create_additions: true)
|
564
564
|
# # Make a nice display.
|
565
|
-
# display =
|
566
|
-
#
|
567
|
-
#
|
568
|
-
#
|
569
|
-
#
|
570
|
-
#
|
571
|
-
#
|
565
|
+
# display = <<~EOT
|
566
|
+
# Generated JSON:
|
567
|
+
# Without custom addition: #{json0} (#{json0.class})
|
568
|
+
# With custom addition: #{json1} (#{json1.class})
|
569
|
+
# Parsed JSON:
|
570
|
+
# Without custom addition: #{obj0.inspect} (#{obj0.class})
|
571
|
+
# With custom addition: #{obj1.inspect} (#{obj1.class})
|
572
572
|
# EOT
|
573
573
|
# puts display
|
574
574
|
#
|
@@ -583,10 +583,5 @@ require 'json/common'
|
|
583
583
|
#
|
584
584
|
module JSON
|
585
585
|
require 'json/version'
|
586
|
-
|
587
|
-
begin
|
588
|
-
require 'json/ext'
|
589
|
-
rescue LoadError
|
590
|
-
require 'json/pure'
|
591
|
-
end
|
586
|
+
require 'json/ext'
|
592
587
|
end
|
metadata
CHANGED
@@ -1,13 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: json
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.
|
4
|
+
version: 2.8.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Florian Frank
|
8
|
+
autorequire:
|
8
9
|
bindir: bin
|
9
10
|
cert_chain: []
|
10
|
-
date: 2024-
|
11
|
+
date: 2024-11-14 00:00:00.000000000 Z
|
11
12
|
dependencies: []
|
12
13
|
description: This is a JSON implementation as a Ruby extension in C.
|
13
14
|
email: flori@ping.de
|
@@ -15,24 +16,20 @@ executables: []
|
|
15
16
|
extensions:
|
16
17
|
- ext/json/ext/generator/extconf.rb
|
17
18
|
- ext/json/ext/parser/extconf.rb
|
18
|
-
- ext/json/extconf.rb
|
19
19
|
extra_rdoc_files:
|
20
20
|
- README.md
|
21
21
|
files:
|
22
|
+
- BSDL
|
22
23
|
- CHANGES.md
|
23
|
-
-
|
24
|
+
- COPYING
|
25
|
+
- LEGAL
|
24
26
|
- README.md
|
25
27
|
- ext/json/ext/fbuffer/fbuffer.h
|
26
|
-
- ext/json/ext/generator/depend
|
27
28
|
- ext/json/ext/generator/extconf.rb
|
28
29
|
- ext/json/ext/generator/generator.c
|
29
|
-
- ext/json/ext/generator/generator.h
|
30
|
-
- ext/json/ext/parser/depend
|
31
30
|
- ext/json/ext/parser/extconf.rb
|
32
31
|
- ext/json/ext/parser/parser.c
|
33
|
-
- ext/json/ext/parser/parser.h
|
34
32
|
- ext/json/ext/parser/parser.rl
|
35
|
-
- ext/json/extconf.rb
|
36
33
|
- json.gemspec
|
37
34
|
- lib/json.rb
|
38
35
|
- lib/json/add/bigdecimal.rb
|
@@ -51,21 +48,21 @@ files:
|
|
51
48
|
- lib/json/add/time.rb
|
52
49
|
- lib/json/common.rb
|
53
50
|
- lib/json/ext.rb
|
51
|
+
- lib/json/ext/generator/state.rb
|
54
52
|
- lib/json/generic_object.rb
|
55
|
-
- lib/json/
|
56
|
-
- lib/json/pure/generator.rb
|
57
|
-
- lib/json/pure/parser.rb
|
53
|
+
- lib/json/truffle_ruby/generator.rb
|
58
54
|
- lib/json/version.rb
|
59
|
-
homepage: https://
|
55
|
+
homepage: https://ruby.github.io/json
|
60
56
|
licenses:
|
61
57
|
- Ruby
|
62
58
|
metadata:
|
63
|
-
bug_tracker_uri: https://github.com/
|
64
|
-
changelog_uri: https://github.com/
|
65
|
-
documentation_uri: https://
|
66
|
-
homepage_uri: https://
|
67
|
-
source_code_uri: https://github.com/
|
68
|
-
wiki_uri: https://github.com/
|
59
|
+
bug_tracker_uri: https://github.com/ruby/json/issues
|
60
|
+
changelog_uri: https://github.com/ruby/json/blob/master/CHANGES.md
|
61
|
+
documentation_uri: https://ruby.github.io/json/doc/index.html
|
62
|
+
homepage_uri: https://ruby.github.io/json
|
63
|
+
source_code_uri: https://github.com/ruby/json
|
64
|
+
wiki_uri: https://github.com/ruby/json/wiki
|
65
|
+
post_install_message:
|
69
66
|
rdoc_options:
|
70
67
|
- "--title"
|
71
68
|
- JSON implementation for Ruby
|
@@ -77,14 +74,15 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
77
74
|
requirements:
|
78
75
|
- - ">="
|
79
76
|
- !ruby/object:Gem::Version
|
80
|
-
version: '2.
|
77
|
+
version: '2.7'
|
81
78
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
82
79
|
requirements:
|
83
80
|
- - ">="
|
84
81
|
- !ruby/object:Gem::Version
|
85
82
|
version: '0'
|
86
83
|
requirements: []
|
87
|
-
rubygems_version: 3.
|
84
|
+
rubygems_version: 3.5.11
|
85
|
+
signing_key:
|
88
86
|
specification_version: 4
|
89
87
|
summary: JSON Implementation for Ruby
|
90
88
|
test_files: []
|
@@ -1 +0,0 @@
|
|
1
|
-
generator.o: generator.c generator.h $(srcdir)/../fbuffer/fbuffer.h
|