Hacker News new | ask | show | jobs
by justsomehnguy 300 days ago
Guessing from the other comments you missed the byte length for the codepoints.

When I'm comparing the human-readable strings I want the letgth. In all other cases I want sizeof(string) and it's... quite a variable thing.