Evo C++ Library v0.5.1
Smart Quoting

When handling delimited text, Evo prefers smart quoting over escape characters:

Smart quoting avoids having to escape characters by using a quoting type adapted to the text being quoted.

Note: Manually applying smart quoting to text can be tricky in certain cases.

Quoting Types

A "field" is the original text, which may contain whitespace, delimiters, and/or quote characters:

A "token" is a field as quoted or unquoted text, which is often followed by a delimiter acting as a separator for the next token:

Single-char quoting:

Triple quoting (inspired by the Python language):

Following the above rules will correctly quote and escape text fields – see below for edge cases.

The non-single-quoting types (above) and edge cases (mentioned below) are rare with normal text, but must be handled correctly when using smart quoting.

No quoting:

Backtick-DEL quoting:

Parsing

Parsers will look for a beginning quote, and if found try to find a matching end-quote followed by a delimiter or end of input.

Formatting

Formatters will check the field text and write it with the appropriate quoting type.