On Wed, Dec 3, 2014 at 11:54 PM, Seth Fowler <s...@mozilla.com> wrote: > So I noticed that we don’t say anything about initializer list formatting in > our coding style guide. I’d like to propose that we standardize this > formatting: > > Foo::Foo(int aBar, char aBaz) > : mBar(aBar) > , mBaz(aBaz) > { > …. > } > > In other words, we should list items in the initializer list one per line. > Each item should be indented two spaces, with the ‘:’ and each ‘,’ vertically > aligned and a space between the ‘:’/‘,’ and the initializer. > > If the entire constructor declaration can fit on one line in 80 characters, > we could relax this rule. In other words, this seems reasonable to me: > > Foo(int aBar) : mBar(aBar) { }
This is the style I use for new code, so I'm in favor of making it the standard one. :) _______________________________________________ dev-platform mailing list dev-platform@lists.mozilla.org https://lists.mozilla.org/listinfo/dev-platform