Skip to content

Two empty string interpolations close to each other give parsing errors #54

Closed
@yaglo

Description

@yaglo

I know it's a bit contrived but it can be an indicator of a bigger underlying issue.

When two strings with empty interpolations are together in one expression, they are being parsed with errors, but are perfectly fine from the Elixir's parser standpoint:

["#{}", "#{}"]
"#{}" <> "#{}"
[one: ~s"#{}", two: ~s"#{}"]

iex:

iex(21)> ["#{}", "#{}"]
["", ""]
iex(22)> "#{}" <> "#{}"
""
iex(23)> [one: ~s"#{}", two: ~s"#{}"]
[one: "", two: ""]

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