Skip to content

Error on concatenation of two strings with a backslash #457

@mbraakhekke

Description

@mbraakhekke

The following minimal program results in a NoMatchError for line 2:

program simple
    character(len=10) :: foo = '\' // 'b'
end program simple

I believe this is correct Fortran--at least it compiles fine on Intel.

I'm still investigating myself. It's doesn't seem to be a problem with the regex pattern for the concat-op. I think it has something to do with the fact that backslashes in strings get automatically escaped to \\ in Python.

Interestingly, if I take out the line from the program block, i.e. just:

character(len=10) :: foo = '\' // 'b'

it works fine.

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