Skip to content

Incorrect highlighting on conditional expression after line continuation #340

Open

Description

@matthewd

In the following code, the else and end are highlighted as belonging to the def: the if appears to be treated as a modifier despite being in an expression context.

def foo
  x = \
    if a
      1
    else
      2
    end
end

Indentation seems to be correspondingly mislead, too.

Activity

  1. tpope commented on Apr 10, 2017

    @tpope
    Member

    Patch welcome, but my fix would be just to delete that worthless backslash.

  2. self-assigned this
    on Feb 22, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions