Get the real length of a string by correctly counting astral symbols