As far as I understand, str
type can be implemented as a regular DST struct:
struct Str([u8]);
Here (play) I have implemented a couple of functions for that struct, and seems like it is possible.
Any reason why str
is a compiler builtin and not a library type, except for historical reasons?