Avoid hanging the compiler when antiquoted expressions include identifiers containing a single quote character

The heuristic for finding the matching closing brace for an antiquoted
region neglected the case where an identifier contains a single quote.
For instance:

    let foo' = 1 in [i|${foo'}|]

would cause the compiler to hang indefinitely.

To avoid this, we do not treat the single quote as introducing a
character literal if it is immediately preceded by a valid identifier
character. This prevents an immediately following closing brace from
being treated as part of a character literal, and thus allows it to
terminate the antiquotation.

This approach is justified by a nuance of the Haskell parser:

    let foo :: Char -> a; foo = undefined
    foo 'c' -- Parses as the function `foo` applied to the character literal `'c'`
    foo'c' -- Parses as the undefined identifier `foo'c'`

In other words, if we are not inside of a string or character literal
quotation, then a single quote character immediately preceded by an
identifier character must be part of an identifier, rather than
introducing a character literal.

Closes #1