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

Expand the readme #23

Merged
merged 2 commits into from
Nov 3, 2020
Merged

Expand the readme #23

merged 2 commits into from
Nov 3, 2020

Conversation

johnynek
Copy link
Collaborator

@johnynek johnynek commented Nov 3, 2020

No description provided.

Below is most of a json parser (the string unescaping is elided). This example can give you a feel
for what it is like to use this library.

```scala
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The more code we put into this, the more risk it rots. Getting this verified with mdoc would be a nice part of #7. But 👍 to getting this out there now.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

totally agree: #24

P.charWhere(c => c >= ' ' && c != '"' && c != '\\')
.rep
.string
P.charsWhile(c => c >= ' ' && c != '"' && c != '\\')
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Stray commit, but I don't think harmful.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeah, I kind of snuck this in... :) I noticed Erik has reimplemented charsWhile and I wanted to use it in the example.

@johnynek johnynek merged commit afb6df9 into main Nov 3, 2020
@johnynek johnynek mentioned this pull request Nov 3, 2020
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

Successfully merging this pull request may close these issues.

2 participants