toUTFindex
fn
size_t toUTFindex(C)(const(C)[] str, size_t n) if (isSomeChar!C) @safe pureGiven a UCS index n into str, returns the UTF index. So, n is how many code points into the string the code point is, and the array index of the code unit is returned.