ruby-changes:58245
From: Sho <ko1@a...>
Date: Mon, 14 Oct 2019 20:54:53 +0900 (JST)
Subject: [ruby-changes:58245] d9e50fcbeb (master): [flori/json] Pass args all #to_json in json/add/*.
https://git.ruby-lang.org/ruby.git/commit/?id=d9e50fcbeb From d9e50fcbeb34534d065f3662b6b952bc57994b43 Mon Sep 17 00:00:00 2001 From: Sho Hashimoto <sho.hsmt@g...> Date: Tue, 15 Jan 2019 22:16:05 +0900 Subject: [flori/json] Pass args all #to_json in json/add/*. https://github.com/flori/json/commit/36a7ef6790 diff --git a/ext/json/lib/json/add/bigdecimal.rb b/ext/json/lib/json/add/bigdecimal.rb index 539daee..c8b4f56 100644 --- a/ext/json/lib/json/add/bigdecimal.rb +++ b/ext/json/lib/json/add/bigdecimal.rb @@ -23,7 +23,7 @@ class BigDecimal https://github.com/ruby/ruby/blob/trunk/ext/json/lib/json/add/bigdecimal.rb#L23 end # return the JSON value - def to_json(*) - as_json.to_json + def to_json(*args) + as_json.to_json(*args) end end diff --git a/ext/json/lib/json/add/complex.rb b/ext/json/lib/json/add/complex.rb index 28ef734..4d977e7 100644 --- a/ext/json/lib/json/add/complex.rb +++ b/ext/json/lib/json/add/complex.rb @@ -23,7 +23,7 @@ class Complex https://github.com/ruby/ruby/blob/trunk/ext/json/lib/json/add/complex.rb#L23 end # Stores class name (Complex) along with real value <tt>r</tt> and imaginary value <tt>i</tt> as JSON string - def to_json(*) - as_json.to_json + def to_json(*args) + as_json.to_json(*args) end end diff --git a/ext/json/lib/json/add/rational.rb b/ext/json/lib/json/add/rational.rb index 356940b..6be4034 100644 --- a/ext/json/lib/json/add/rational.rb +++ b/ext/json/lib/json/add/rational.rb @@ -22,7 +22,7 @@ class Rational https://github.com/ruby/ruby/blob/trunk/ext/json/lib/json/add/rational.rb#L22 end # Stores class name (Rational) along with numerator value <tt>n</tt> and denominator value <tt>d</tt> as JSON string - def to_json(*) - as_json.to_json + def to_json(*args) + as_json.to_json(*args) end end diff --git a/ext/json/lib/json/add/regexp.rb b/ext/json/lib/json/add/regexp.rb index a93866b..39d69fe 100644 --- a/ext/json/lib/json/add/regexp.rb +++ b/ext/json/lib/json/add/regexp.rb @@ -24,7 +24,7 @@ class Regexp https://github.com/ruby/ruby/blob/trunk/ext/json/lib/json/add/regexp.rb#L24 # Stores class name (Regexp) with options <tt>o</tt> and source <tt>s</tt> # (Regexp or String) as JSON string - def to_json(*) - as_json.to_json + def to_json(*args) + as_json.to_json(*args) end end -- cgit v0.10.2 -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/