@whitequark borrow worries me because many uses of an index stop working with a borrow. For example, what if you want two indices so you can interate over the string twice. Ofc the index idea only works if you can prevent the string from being mutated…
@robryk But it would be nice if I could do at least some arithmetic on the potentially opaque object (doesn't have to be through default operators), such as comparison or incrementing.
@robryk I mean the abstract data type of an index. An entity, potentially opaque, that can be used as an internal pointer into the string.