I haven't been part of the conversations surrounding this specific proposal, so apologies if I'm retreading previous discussions. I'm not specifically hoping to effect a concrete change to the proposal with this question - I mainly want to understand the design better.
The operations on the stringref type already seem rather opinionated in the actual encodings supported - (e.g. encode_wtf16 and encode_wtf8). Moreover, the current proposal introduces separate view types for wtf16 and wtf8. Was a design considered where there are separate stringref_wtf16 and stringref_wtf8 types instead of a "unified" stringref type? IIUC this would eliminate the need for separate view types (except perhaps stringview_iter).
I haven't been part of the conversations surrounding this specific proposal, so apologies if I'm retreading previous discussions. I'm not specifically hoping to effect a concrete change to the proposal with this question - I mainly want to understand the design better.
The operations on the
stringreftype already seem rather opinionated in the actual encodings supported - (e.g.encode_wtf16andencode_wtf8). Moreover, the current proposal introduces separateviewtypes forwtf16andwtf8. Was a design considered where there are separatestringref_wtf16andstringref_wtf8types instead of a "unified"stringreftype? IIUC this would eliminate the need for separate view types (except perhapsstringview_iter).