You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It looks like if I were to pass a NonEmptyArray an input of type Range or ClosedRange, NonEmptyArray actually produces an array comprising a single element, which is that range itself, instead of an array comprising the numbers within the range:
I tried creating a fix myself so I could just create a PR and save you all time, but I'm struggling to get a way to generate the expanded array and map that to an existing NonEmpty convenience initializer. Maybe I'm the only one in the world to try and use NonEmptyArray in this manner and it's not worth the effort ;)
The text was updated successfully, but these errors were encountered:
acosmicflamingo
changed the title
Range/ClosedRange as input to NonEmpty initializer
Range/ClosedRange input support for NonEmpty initializer
Feb 10, 2023
It looks like if I were to pass a NonEmptyArray an input of type
Range
orClosedRange
, NonEmptyArray actually produces an array comprising a single element, which is that range itself, instead of an array comprising the numbers within the range:I tried creating a fix myself so I could just create a PR and save you all time, but I'm struggling to get a way to generate the expanded array and map that to an existing NonEmpty convenience initializer. Maybe I'm the only one in the world to try and use NonEmptyArray in this manner and it's not worth the effort ;)
The text was updated successfully, but these errors were encountered: