void String::print(String *str){ char *st= (char*)Ptr, *end= st+str_length; for (; st < end; st++) { uchar c= *st; switch (c) { case '\\': str->append(STRING_WITH_LEN("\\\\")); break; case '\0': str->append(STRING_WITH_LEN("\\0")); break; case '\'': str->append(STRING_WITH_LEN("\\'")); break; case '\n': str->append(STRING_WITH_LEN("\\n")); break; case '\r': str->append(STRING_WITH_LEN("\\r")); break; case '\032': // Ctrl-Z str->append(STRING_WITH_LEN("\\Z")); break; default: str->append(c); } }}