The prefix idea is genius! Although I don't know how suited it is for mutable 
strings. Because it would need to be updated for every mutable operation. I 
think the best implementation for nim would have both 1bit isLong/short flag 
and a payload type with two int32s capacity and refcount fields.

Reply via email to