From 7f4cfd853f2c919d854fb95548a19980feff17e8 Mon Sep 17 00:00:00 2001 From: Florian Frank Date: Fri, 13 Jan 2017 12:05:07 +0100 Subject: Try to be compatible with ruby 1.8 --- CHANGES | 3 +++ VERSION | 2 +- ext/json/ext/generator/generator.h | 4 ++++ json.gemspec | Bin 5908 -> 5908 bytes json_pure.gemspec | 6 +++--- lib/json/version.rb | 2 +- 6 files changed, 12 insertions(+), 5 deletions(-) diff --git a/CHANGES b/CHANGES index cb0019e..5b92bbe 100644 --- a/CHANGES +++ b/CHANGES @@ -1,4 +1,7 @@ +2017-01-13 (1.8.6) + * Be compatible with ancient ruby 1.8 (maybe?) 2015-09-11 (1.8.5) + * Be compatible with ruby 2.4.0 * There were still some mentions of dual GPL licensing in the source, but JSON has just the Ruby license that itself includes an explicit dual-licensing clause that allows covered software to be distributed under the terms of diff --git a/VERSION b/VERSION index 8decb92..f263cd1 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -1.8.5 +1.8.6 diff --git a/ext/json/ext/generator/generator.h b/ext/json/ext/generator/generator.h index eb4557f..3559864 100644 --- a/ext/json/ext/generator/generator.h +++ b/ext/json/ext/generator/generator.h @@ -21,6 +21,10 @@ #define rb_obj_instance_variables(object) rb_funcall(object, rb_intern("instance_variables"), 0) #endif +#ifndef RB_TYPE_P +#define RB_TYPE_P(obj, type) (rb_type(obj) == type) +#endif + #define option_given_p(opts, key) RTEST(rb_funcall(opts, i_key_p, 1, key)) /* unicode definitions */ diff --git a/json.gemspec b/json.gemspec index 635c91a..a6cf2a0 100644 Binary files a/json.gemspec and b/json.gemspec differ diff --git a/json_pure.gemspec b/json_pure.gemspec index b783448..723ed77 100644 --- a/json_pure.gemspec +++ b/json_pure.gemspec @@ -1,14 +1,14 @@ # -*- encoding: utf-8 -*- -# stub: json_pure 1.8.5 ruby lib +# stub: json_pure 1.8.6 ruby lib Gem::Specification.new do |s| s.name = "json_pure".freeze - s.version = "1.8.5" + s.version = "1.8.6" s.required_rubygems_version = Gem::Requirement.new(">= 0".freeze) if s.respond_to? :required_rubygems_version= s.require_paths = ["lib".freeze] s.authors = ["Florian Frank".freeze] - s.date = "2017-01-12" + s.date = "2017-01-13" s.description = "This is a JSON implementation in pure Ruby.".freeze s.email = "flori@ping.de".freeze s.extra_rdoc_files = ["README.md".freeze] diff --git a/lib/json/version.rb b/lib/json/version.rb index 2a17091..3603d71 100644 --- a/lib/json/version.rb +++ b/lib/json/version.rb @@ -1,6 +1,6 @@ module JSON # JSON version - VERSION = '1.8.5' + VERSION = '1.8.6' VERSION_ARRAY = VERSION.split(/\./).map { |x| x.to_i } # :nodoc: VERSION_MAJOR = VERSION_ARRAY[0] # :nodoc: VERSION_MINOR = VERSION_ARRAY[1] # :nodoc: -- cgit v1.2.1