Re: style guide proposal

2014-09-29 Thread Nicholas Nethercote
On Mon, Sep 29, 2014 at 3:46 PM, Julian Viereck wrote: > > Maybe we could use a hierarchical structure for the lint rules. At the top of > the tree there are general rules, that are very weak - e.g. don't have > trailing white-spaces and a maximum of 100 characters per line. Further down > into

Re: style guide proposal

2014-09-29 Thread Julian Viereck
On Thursday, December 19, 2013 6:28:07 PM UTC+1, Bobby Holley wrote: > Off-the-shelf automated tools are not going to solve our formatting woes. > > Both the JS engine and Gecko mandate very particular patterns. I ended up > > writing a custom python tool to reformat XPConnect a few years ago [1]

Re: style guide proposal

2013-12-19 Thread Anthony Jones
On 20/12/13 11:55, Mike Hommey wrote: > On Thu, Dec 19, 2013 at 11:02:08AM -0500, Ehsan Akhgari wrote: >> clang-format has a basic support for the Mozilla coding style, and we can >> definitely extend it to add support for this heuristic. > > I don't think we should care about having a Mozilla-sp

Re: style guide proposal

2013-12-19 Thread Mike Hommey
On Thu, Dec 19, 2013 at 11:02:08AM -0500, Ehsan Akhgari wrote: > > How about we just use clang-format? > > http://www.irill.org/videos/euro-llvm-2013/jasper-hires.webm > > > clang-format has a basic support for the Mozilla coding style, and we can > definitely extend it to add support for this h

Re: style guide proposal

2013-12-19 Thread Martin Thomson
. - Original Message - From: "Bobby Holley" To: "Martin Thomson" Cc: "Till Schneidereit" , "Mike Hommey" , "Ehsan Akhgari" , dev-platform@lists.mozilla.org, "Andrea Marchesini" Sent: Thursday, December 19, 2013 9:28:07 AM Subjec

Re: style guide proposal

2013-12-19 Thread Bobby Holley
lly not worry about >> formatting. >> >> ----- Original Message - >> From: "Till Schneidereit" >> To: "Ehsan Akhgari" >> Cc: "Mike Hommey" , dev-platform@lists.mozilla.org, >> "Andrea Marchesini" >> Sent:

Re: style guide proposal

2013-12-19 Thread Gregory Szorc
quot; To: "Ehsan Akhgari" Cc: "Mike Hommey" , dev-platform@lists.mozilla.org, "Andrea Marchesini" Sent: Thursday, December 19, 2013 8:11:39 AM Subject: Re: style guide proposal [...] I think we should increase the checking we do, and make it a habit to run the checks b

Re: style guide proposal

2013-12-19 Thread Bobby Holley
uot;did you > run {clang-format,astyle,js-beautify}", but generally not worry about > formatting. > > - Original Message - > From: "Till Schneidereit" > To: "Ehsan Akhgari" > Cc: "Mike Hommey" , dev-platform@lists.mozilla.org, > &qu

Re: style guide proposal

2013-12-19 Thread Martin Thomson
"Ehsan Akhgari" Cc: "Mike Hommey" , dev-platform@lists.mozilla.org, "Andrea Marchesini" Sent: Thursday, December 19, 2013 8:11:39 AM Subject: Re: style guide proposal [...] I think we should increase the checking we do, and make it a habit to run the checks before tr

Re: style guide proposal

2013-12-19 Thread Till Schneidereit
On Thu, Dec 19, 2013 at 5:02 PM, Ehsan Akhgari wrote: > -- > Ehsan > > > > On Thu, Dec 19, 2013 at 4:32 AM, Mike Hommey wrote: > > How about we just use clang-format? > > http://www.irill.org/videos/euro-llvm-2013/jasper-hires.webm > > > clang-format has a basic suppor

Re: style guide proposal

2013-12-19 Thread Martin Thomson
eller" To: "Mike Hommey" , "Andrea Marchesini" Cc: dev-platform@lists.mozilla.org Sent: Thursday, December 19, 2013 7:29:28 AM Subject: Re: style guide proposal I'd love that. Also, something similar for JS would be nice. Cheers, David On 12/19/13 10:32 AM, Mike Hom

Re: style guide proposal

2013-12-19 Thread Ehsan Akhgari
-- Ehsan On Thu, Dec 19, 2013 at 4:32 AM, Mike Hommey wrote: > On Thu, Dec 19, 2013 at 01:20:41AM -0800, Andrea Marchesini wrote: > > Hi, > > > > Writing a patch for bug 949488 I had to indent this piece of code: > > > > nsIScriptSecurityManager* ssm = nsContentUtil

Re: style guide proposal

2013-12-19 Thread David Rajchenbach-Teller
I'd love that. Also, something similar for JS would be nice. Cheers, David On 12/19/13 10:32 AM, Mike Hommey wrote: > How about we just use clang-format? > http://www.irill.org/videos/euro-llvm-2013/jasper-hires.webm > > Mike > ___ > dev-platform mail

Re: style guide proposal

2013-12-19 Thread Ms2ger
On 12/19/2013 10:20 AM, Andrea Marchesini wrote: Hi, Writing a patch for bug 949488 I had to indent this piece of code: nsIScriptSecurityManager* ssm = nsContentUtils::GetSecurityManager(); if (NS_WARN_IF(NS_FAILED(ssm->GetSimpleCodebasePrincipal( o

Re: style guide proposal

2013-12-19 Thread Mike Hommey
On Thu, Dec 19, 2013 at 01:20:41AM -0800, Andrea Marchesini wrote: > Hi, > > Writing a patch for bug 949488 I had to indent this piece of code: > > nsIScriptSecurityManager* ssm = nsContentUtils::GetSecurityManager(); > if (NS_WARN_IF(NS_FAILED(ssm->GetSimpleCodebasePrincipal( >