In case Savi gets FAT pointers, could a string slice which String'val effectively is, be encoded more efficiently by using a special encoding for the vtable pointer to include the length of the string and the pointer itself to point directly to the string data?
This would make any string slicing or parsing operations be very efficient (similar to Rust), as no allocation would be required anymore when creating a new slice. The length of a string slice encoded as such has to be limited to less than 64-bits.
In case Savi gets FAT pointers, could a string slice which
String'val
effectively is, be encoded more efficiently by using a special encoding for the vtable pointer to include the length of the string and the pointer itself to point directly to the string data?This would make any string slicing or parsing operations be very efficient (similar to Rust), as no allocation would be required anymore when creating a new slice. The length of a string slice encoded as such has to be limited to less than 64-bits.
The same could be done with Array slices.