Actions
Feature #20469
closedAdd a JSON addition for Enumerator::ArithmeticSequence
Status:
Third Party's Issue
Assignee:
-
Target version:
-
Description
There's a JSON addition for Range
but one wasn't added for Enumerator::ArithmeticSequence
when it was introduced. This little PR adds a JSON addition for ArithmeticSequence for parity with a normal Range. https://github.com/ruby/ruby/pull/10720/files
##
# Already supported
require 'json/add/range'
(0..42).to_json
##
# Proposed addition
require 'json/add/arithmetic_sequence'
((0..42) % 3).to_json
I was curious about adding it to add/core.rb
but it seems like that could be considered separately, especially since there are classes like Set that could also be considered for inclusion now that it's a core class.
Updated by shan (Shannon Skipper) 7 months ago
I just realized I filed my PR in the wrong place since JSON is a gem. (Sorry for the noise.) I closed the previous PR and opened one in the JSON gem repo. https://github.com/flori/json/pull/583
Updated by hsbt (Hiroshi SHIBATA) 7 months ago
- Status changed from Open to Third Party's Issue
Actions
Like0
Like0Like0