0
David Capello 6 years ago • updated by Ryan Park 6 years ago 3

With the following code on C/C++/JavaScript/C-like languages: (note: _ is the cursor position)

  if (a == b ||
      c == d) _
If we press { and then ENTER key, we get:
if (a == b ||
    a == c) {
        _
    }

Which is invalid, we should get:

if (a == b ||
    a == c) {
    _
}

Even jQuery source code use this kind of indentation.
+1
It's quite interesting to see that people can vote down a bug. lol
Yes I agree, this indentation style is not uncommon.