-
Notifications
You must be signed in to change notification settings - Fork 122
Add data
and start_offset
methods for StringView
#2090
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
base: main
Are you sure you want to change the base?
Conversation
Documentation could be more specific about UTF-16 code unitsCategory Missing documentation for data() method's ownership semanticsCategory Test cases could be more comprehensiveCategory |
Pull Request Test Coverage Report for Build 6680Details
💛 - Coveralls |
Is there a reason that you are using |
The reason for using
|
Although I don't think it's a bad idea to add these functions, I don't think your reasons hold. You can pass the |
Yes, the C prototype of |
Solely for your case, I think you don't even need the encoder or |
Right, in this func, it can be handled better as you suggested. |
However, in other cases, when the amount of data contained in |
The
StringView
currently lacks methods to obtain raw data and starting offset, which hinders seamless switching betweenStringView
andString
.Here is an example: