Skip to content

Allow splitting string literals over multiple lines #7292

@axic

Description

@axic

Many languages support splitting string literals overs multiple lines. Some require a special token between them.

I'd propose that parsing (hex) string literals would allow " as the next token and start concatenating the literals. Any whitespace, including new lines, would be allowed between the two " tokens.

E.g. bytes tmp = hex"00112233" "44556677"; would be equivalent to hex"0011223344556677".

Metadata

Metadata

Assignees

No one assigned

    Labels

    language design :rage4:Any changes to the language, e.g. new features

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions