oj 2.14.5 → 2.14.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +2 -3
- data/ext/oj/oj.c +7 -3
- data/lib/oj/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a4eeac461218d534327dc278a6dfe132de7227bb
|
4
|
+
data.tar.gz: 9197b3baa13fe3077519d6156a9d9dbbd1176066
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1a89867a9e4e684a3d0f268e18179d54f63471a0b8f3fed3ed174a11b5dc3f0cd582bce893955de582e57872985196c6dd671078624b1de4bbfb17805508e9ef
|
7
|
+
data.tar.gz: 9eb8668bbc77cc0a3057321706f08bbded75ab0bca623964554796bdc9835ede42e34b36a596f64637a81461b9bc9a67d94cd5d46ee8fca5fce04c8a9ab5f6cb
|
data/README.md
CHANGED
@@ -159,10 +159,9 @@ Oj.default_options = {:mode => :compat }
|
|
159
159
|
|
160
160
|
## Releases
|
161
161
|
|
162
|
-
**Release 2.14.
|
162
|
+
**Release 2.14.6**
|
163
163
|
|
164
|
-
-
|
165
|
-
displayed name is JSON::ParserError instead.
|
164
|
+
- Changed JSON::ParserError to inherit from JSON::JSONError which inherits from StandardError.
|
166
165
|
|
167
166
|
[Older release notes](http://www.ohler.com/dev/oj_misc/release_notes.html).
|
168
167
|
|
data/ext/oj/oj.c
CHANGED
@@ -1881,7 +1881,8 @@ static VALUE
|
|
1881
1881
|
define_mimic_json(int argc, VALUE *argv, VALUE self) {
|
1882
1882
|
VALUE ext;
|
1883
1883
|
VALUE dummy;
|
1884
|
-
|
1884
|
+
VALUE json_error;
|
1885
|
+
|
1885
1886
|
// Either set the paths to indicate JSON has been loaded or replaces the
|
1886
1887
|
// methods if it has been loaded.
|
1887
1888
|
if (rb_const_defined_at(rb_cObject, rb_intern("JSON"))) {
|
@@ -1944,11 +1945,14 @@ define_mimic_json(int argc, VALUE *argv, VALUE self) {
|
|
1944
1945
|
create_additions_sym = ID2SYM(rb_intern("create_additions")); rb_gc_register_address(&create_additions_sym);
|
1945
1946
|
symbolize_names_sym = ID2SYM(rb_intern("symbolize_names")); rb_gc_register_address(&symbolize_names_sym);
|
1946
1947
|
|
1948
|
+
if (rb_const_defined_at(mimic, rb_intern("JSONError"))) {
|
1949
|
+
rb_funcall(mimic, rb_intern("remove_const"), 1, ID2SYM(rb_intern("JSONError")));
|
1950
|
+
}
|
1951
|
+
json_error = rb_define_class_under(mimic, "JSONError", rb_eStandardError);
|
1947
1952
|
if (rb_const_defined_at(mimic, rb_intern("ParserError"))) {
|
1948
1953
|
rb_funcall(mimic, rb_intern("remove_const"), 1, ID2SYM(rb_intern("ParserError")));
|
1949
1954
|
}
|
1950
|
-
rb_define_class_under(mimic, "ParserError",
|
1951
|
-
json_parser_error_class = rb_const_get(mimic, rb_intern("ParserError"));
|
1955
|
+
json_parser_error_class = rb_define_class_under(mimic, "ParserError", json_error);
|
1952
1956
|
|
1953
1957
|
if (!rb_const_defined_at(mimic, rb_intern("State"))) {
|
1954
1958
|
rb_define_class_under(mimic, "State", rb_cObject);
|
data/lib/oj/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: oj
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.14.
|
4
|
+
version: 2.14.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Peter Ohler
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-02-
|
11
|
+
date: 2016-02-26 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rake-compiler
|