parameters: (text)
return_statement: return str(out)
docstring: Convert unicode text into ascii and escape quotes and backslashes.
docstring_summary: Convert unicode text into ascii and escape quotes and backslashes.
docstring_tokens: Convert unicode text into ascii and escape quotes and backslashes .
function: def utoascii(text):
      """
      Convert unicode text into ascii and escape quotes and backslashes.
      """
      if text is None:
          return ''
      out = text.encode('ascii', 'replace')
      # swig will require us to replace blackslash with 4 backslashes
      # TODO: evaluate what this should be for pybind11
      out = out.replace(b'\\', b'\\\\\\\\')
      out = out.replace(b'"', b'\\"').decode('ascii')
      return str(out)
function_tokens: def utoascii ( text ) : if text is None : return '' out = text . encode ( 'ascii' , 'replace' ) # swig will require us to replace blackslash with 4 backslashes # TODO: evaluate what this should be for pybind11 out = out . replace ( b'\\' , b'\\\\\\\\' ) out = out . replace ( b'"' , b'\\"' ) . decode ( 'ascii' ) return str ( out )