-
-
Notifications
You must be signed in to change notification settings - Fork 1
Add support for Named Callouts #21
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
Conversation
do you want to handle all errors gracefully? |
Independent of #13, it's important that all invalid patterns throw with a custom message. How narrow/specific those errors should be (and how much information should be included in the message) is partly a matter of taste, so it might depend on the case. Where to throw errors might also be a bit ambiguous, but probably has a "correct" answer in most cases, be it in the tokenizer, the parser's |
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.
Amazing that you went for full named callout support rather than just (*FAIL)
!
Thanks!!
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.
Awesome work. This complex feature is really coming together. Looking forward to it!
I've made some minor changes to the parser in recent diffs, so it might be helpful to also rebase on the latest changes.
tf is wrong with git I do it again I even checked the commit hashes EDIT: |
Great stuff! ππ Thanks for putting up with the back and forth, and doing excellent work on this. I've made some follow-up tweaks and added some tests in 1ea0179. Some changes are just nitpicky style and personal preference things (or done for consistency with code elsewhere), but a handful are worth observing. One probably non-obvious thing is I removed a couple uses of
|
looks good when renaming and modifying files I wasn't sure that |
Good advice on splitting commits. I'll try to do that in the future. |
Published in v0.9.0. |
basic callout tokenizing and parsing so far
https://github.com/kkos/oniguruma/blob/master/doc/RE#L352-L359
https://github.com/kkos/oniguruma/blob/master/doc/CALLOUTS.BUILTIN
https://github.com/kkos/oniguruma/blob/master/src/ascii.c#L35-L75
slevithan/oniguruma-to-es#20
dup #15