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

Removes force downcast in favor of condidional cast in switch #137

Merged
merged 1 commit into from
Mar 31, 2024

Conversation

lightsprint09
Copy link
Member

While implementing URL support I found an elegant way to get rid of force casting in EncodingConatiners. Should not be slower, maybe even faster.

@heckj
Copy link
Collaborator

heckj commented Mar 31, 2024

Looks good - drops to a single comparison. Didn't benchmark it, but I expect it would be at least slightly faster.

@lightsprint09 lightsprint09 merged commit a9f5012 into main Mar 31, 2024
4 checks passed
@heckj heckj deleted the remove-explicit-downcast branch May 25, 2024 00:16
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