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

Closing braces aren't checked. [ } is a valid list. #40

Open
luke-clifton opened this issue Dec 19, 2018 · 3 comments
Open

Closing braces aren't checked. [ } is a valid list. #40

luke-clifton opened this issue Dec 19, 2018 · 3 comments
Labels
bug Something isn't working

Comments

@luke-clifton
Copy link
Contributor

λ import Types.Common (parseBS)  -- From the test suite
λ import Waargonaut.Decode as D
λ D.runPureDecode (D.list D.int) parseBS $ D.mkCursor "[]"
Right []
λ D.runPureDecode (D.list D.int) parseBS $ D.mkCursor "[}"  -- <--- oops
Right []
@luke-clifton
Copy link
Contributor Author

λ D.runPureDecode (D.list D.int) parseBS $ D.mkCursor "["
Right []

@mankyKitty mankyKitty added the bug Something isn't working label Dec 19, 2018
@mankyKitty
Copy link
Contributor

There is a nicer fix that I am able to add once we have #39 merged. The succinct data structures make it trivial and fast to confirm the closing element of a structure, so should be straightforward.

@emilypi
Copy link
Member

emilypi commented Jan 20, 2021

@mankyKitty is it safe to say this issue was fixed as of #42 ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants