Skip to content

CSharp grammar has incorrect definition of Interpolated Strings #1146

@attodorov

Description

@attodorov

From the grammar:

interpolated_verbatium_string_part
	: interpolated_string_expression
	| DOUBLE_CURLY_INSIDE
	| VERBATIUM_DOUBLE_QUOTE_INSIDE
	| VERBATIUM_INSIDE_STRING
	;

It's not a double curly by spec. It's a single curly. Here's the correct def:

https://docs.microsoft.com/en-us/dotnet/csharp/language-reference/tokens/interpolated

So the grammar should be

interpolated_verbatium_string_part
	: interpolated_string_expression
	| SINGLE_CURLY_INSIDE
	| VERBATIUM_DOUBLE_QUOTE_INSIDE
	| VERBATIUM_INSIDE_STRING
	;

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions