Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Lazy sequence is reversed in coercion #176

Closed
salokristian opened this issue Apr 10, 2019 · 2 comments
Closed

Lazy sequence is reversed in coercion #176

salokristian opened this issue Apr 10, 2019 · 2 comments

Comments

@salokristian
Copy link
Contributor

Library version

0.9.1

Problem

When a lazy seq is given to st/coerce, it is reversed.

Given a coll-of spec

(s/def ::coll-spec (s/coll-of int?))

And a lazy seq as input

(st/coerce ::coll-spec (lazy-seq '(1 2 3)) st/string-transformer)
=> (3 2 1)

The resulting list is reversed.

@salokristian
Copy link
Contributor Author

I can also look into this myself this weekend.

@jrasanen
Copy link

Thanks, I think we fixed that for the 0.9.0 version, but maybe it's a regression or we missed some case.

@salokristian salokristian reopened this Apr 10, 2019
salokristian added a commit to salokristian/spec-tools that referenced this issue Apr 13, 2019
salokristian added a commit to salokristian/spec-tools that referenced this issue Apr 13, 2019
ikitommi added a commit that referenced this issue Apr 25, 2019
[Fix #176] Fix reversion of lazy sequences in coercion
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants