Emits a D parse tree as Python code.
Enumeration of flags that indicate what's contained in a string.
Searches for backslashes, quotes and newlines in a string.
Replaces \ with \\ and " with \".
Returns the number of characters if ws contains only ' ' chars, otherwise returns ws in single quotes.