-
Notifications
You must be signed in to change notification settings - Fork 145
Implemented TH splices for validated ByteString literals #712
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
base: master
Are you sure you want to change the base?
Conversation
thLiteral :: Quote m => String -> Code m ByteString thHexLiteral :: Quote m => String -> Code m ByteString The former rejects inputs with non-octet code points above 0xFF. The latter rejects odd-length inputs or inputs with characters other than non-hexadecimal digits.
70f1a6a
to
b53c921
Compare
@Bodigrim I don't understand what's going on with CI. Any help appreciated. |
@vdukhovni no idea tbh. Maybe something changed under the hood, either in runner images or in the haskell action. |
I have very little experience tuning GitHub CI. Any chance someone can help? |
It seems it was an intermittent failure with https://github.com/haskell-actions/setup. I don't think you need to touch CI setup in this PR. |
Thanks, indeed most of the problems appear to have been transient. I reverted the CI changes, and the only failure so far is with Otherwise, no issues. So I think I'm done, unless you'd prefer to name the two functions differently. The names |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
I would prefer more explicit names: something like literalFromAscii
(or literalFromChar8
) and literalFromHex
Many thanks for the prompt review! I'm about to push a fixup for all the nits, and what remains then is to reach consensus on the splice names. Of the above I prefer |
Yes the type and |
Henry Sylvain review fixups
Andrew Lelechenko review fixes
The former rejects inputs with non-octet code points above 0xFF. The latter rejects odd-length inputs or inputs with characters other than non-hexadecimal digits.