Dan Sugalski <[EMAIL PROTECTED]> wrote: > If you want, you could think of the S-register strings as mini-PMCs. > The encoding and charset stuff (we'll ignore language semantics for > the moment) are essentially small vtables that hang off the string,
I think its the cleanest way of implementing all that string mess. Want some {byte, code point, grapheme} string length: call string->str_vtable->length. Want to SHR an Unicode string, the vtable throws an exception. The question is: which of all these vtables depend on the string and which are "environment" things. If there are a reaonable amount of the former, a vtable is the way to go IMHO. And there are or course some binary ops like concat but not much. leo