mark-wiemer-org/ahkpp

Strange behavior while moving code using built-in indentation rules in VS Code

Opened this issue · 2 comments

Description

Strange behavior while moving code using built-in indentation rules in VS Code .\language\ahk.configuration.json parameter indentNextLinePattern.

Example

Possible wrong state while moving var

if (expr)
    var
    code

Hey, this may be related to the comments. I'm not able to repro the issue with this snippet, are you?

var
foo() {
    if expression
        code
    code
    if (expression)
        code
    if (expression) {
        code
    }
    
}

Now I see strange behavior in both directions :)

Initial (move var down)

var
if (expr)
    code
code

Expected

if (expr)
    var
code
code

Actual

if (expr)
    var
    code ;<-- why there indent?
code