Skip to content

Document supported escape sequences for string literals #117

@patjakdev

Description

@patjakdev

What were you trying to do?

Understand the syntax for escaping unicode code points and other characters in string literals.

What is wrong and why?

The Policy grammar page describes the string literal syntax as:

STR ::= Fully-escaped Unicode surrounded by '"'s

But it doesn't explain how to escape the unicode at all. Upon reading the Rust library source code, I found it somewhat surprising that the Rustic approach of \u{x...} is used which is somewhat different from many other libraries which use the fixed-width \uxxxx escape approach.

What do we need to do to fix this?

Document how to escape characters (a leading \) and what escape sequences are supported (n, r, u{...}, etc).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions