Skip to content

parse fail with here document with variable #136

Closed
@ARCowie28

Description

@ARCowie28

Parse fails for entire document when you have a here document inside an if, that contains a variable as the first expression.

MWE:

if true; then
  a_string='some stuff to cat'
  cat <<XXX
${a_string}
XXX
fi

Issue does not occur if:

  • not inside an if
  • there is anything except newlines before ${a_string}, including whitespace

Metadata

Metadata

Assignees

No one assigned

    Labels

    grammar bugIssues related to the bash grammar

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions