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

Use generics for ddd escape parsing #1435

Merged
merged 2 commits into from
Mar 12, 2023
Merged

Conversation

tmthrgd
Copy link
Collaborator

@tmthrgd tmthrgd commented Mar 12, 2023

We use generics to merge dddToByte and dddStringToByte.

We also introduce a generic isDDD helper that replaces nearly all uses of isDigit. The exception being svcbParseParam which implements stricter parsing.

Almost all uses of isDigit look exactly the same, turn them into a
matching helper.
@tmthrgd tmthrgd requested a review from miekg as a code owner March 12, 2023 11:22
@miekg miekg merged commit 4c50fd8 into miekg:master Mar 12, 2023
@tmthrgd tmthrgd deleted the generic_dddToByte branch March 12, 2023 14:46
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