I'm trying to use vim to edit source code for AutoHotkey.
This is how the source code looks when correctly formatted:
if foo
{
if bar = 1
callFunc1()
if bar = 2
callFunc2()
if bar = 3
callFunc3()
}
If I do =G, then this is what vim changes it to:
if foo
{
if bar = 1
callFunc1()
if bar = 2
callFunc2()
if bar = 3
callFunc3()
}
I had other formatting problems with this source code that was solved by using :set cindent cinoptions=+0
, but that does not solve this problem.