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

Allow indexing/slicing bytes with byteIndex #14695

Merged
merged 1 commit into from
Jan 7, 2020

Conversation

e-kayrakli
Copy link
Contributor

@e-kayrakli e-kayrakli commented Dec 21, 2019

This PR enables indexing and slicing bytes using byteIndex type.

byteIndex is a type used in string indexing to differentiate codepoint
indexing and byte indexing. While writing some generic code using strings and
bytes, it'd be nice to be able to index/slice bytes using this type, too.

For the motivation see:
#14686 (comment)

Test:

  • full standard
  • full gasnet

@e-kayrakli e-kayrakli merged commit 3d9e280 into chapel-lang:master Jan 7, 2020
@e-kayrakli e-kayrakli deleted the bytes-byteIndex branch January 7, 2020 00:57
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