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

urlEncode() should only copy if necessary #1076

Merged
merged 1 commit into from May 12, 2015

Conversation

Projects
None yet
2 participants
@schuetzm
Contributor

schuetzm commented Apr 25, 2015

No description provided.

@s-ludwig

This comment has been minimized.

Show comment
Hide comment
@s-ludwig

s-ludwig May 1, 2015

Member

Could allOf make use of a sorted input array of characters and use a binary search (i.e. using assumeSorted)? Otherwise I'd use a switch range statement or an AA instead for efficiency reasons. Also for efficiency, using str.representation.allOf is preferred to avoid unnecessary UTF decoding.

Member

s-ludwig commented May 1, 2015

Could allOf make use of a sorted input array of characters and use a binary search (i.e. using assumeSorted)? Otherwise I'd use a switch range statement or an AA instead for efficiency reasons. Also for efficiency, using str.representation.allOf is preferred to avoid unnecessary UTF decoding.

@schuetzm

This comment has been minimized.

Show comment
Hide comment
@schuetzm

schuetzm May 1, 2015

Contributor

I changed it to a switch statement. Both DMD and LDC compile it into a lookup table.

Contributor

schuetzm commented May 1, 2015

I changed it to a switch statement. Both DMD and LDC compile it into a lookup table.

@s-ludwig

This comment has been minimized.

Show comment
Hide comment
@s-ludwig

s-ludwig May 12, 2015

Member

Thanks, that should work.

Member

s-ludwig commented May 12, 2015

Thanks, that should work.

s-ludwig added a commit that referenced this pull request May 12, 2015

Merge pull request #1076 from schuetzm/urlencode-dont-copy
urlEncode() should only copy if necessary

@s-ludwig s-ludwig merged commit 113a6b8 into vibe-d:master May 12, 2015

1 check failed

continuous-integration/travis-ci/pr The Travis CI build failed
Details

@schuetzm schuetzm deleted the schuetzm:urlencode-dont-copy branch May 12, 2015

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment