language-python-0.3.2: Parsing and pretty printing of Python code.

Portabilityghc
Stabilityexperimental
Maintainerbjpop@csse.unimelb.edu.au

Language.Python.Common.StringEscape

Contents

Description

Conversion to/from escaped characters in strings. Note: currently does not support escaped Unicode character names.

See:

Synopsis

String conversion.

unescapeString :: String -> StringSource

Convert escaped sequences of characters into real characters in a normal Python string.

unescapeRawString :: String -> StringSource

Convert escaped sequences of characters into real characters in a raw Python string. Note: despite their name, Python raw strings do allow a small set of character escapings, namely the single and double quote characters and the line continuation marker.

Digits allowed in octal and hex representation.