Re: [PATCH] D11837: Add Qt brace style configuration option.

2015-08-10 Thread Roman Kashitsyn via cfe-commits
lifted updated this revision to Diff 31660. lifted added a comment. Removed Qt brace style, add WebKit brace style. Changed default brace style in the WebKit configuration to BS_WebKit. http://reviews.llvm.org/D11837 Files: docs/ClangFormatStyleOptions.rst include/clang/Format/Format.h l

Re: [PATCH] D11837: Add Qt brace style configuration option.

2015-08-10 Thread Manuel Klimek via cfe-commits
klimek added a comment. Ah, ok. Interestingly, our current Webkit style uses BS_Stroustrup, which is incorrect for } else {. So yep, implementing BS_Webkit sounds like a win. http://reviews.llvm.org/D11837 ___ cfe-commits mailing list cfe-commits@

Re: [PATCH] D11837: Add Qt brace style configuration option.

2015-08-10 Thread Roman Kashitsyn via cfe-commits
lifted added a comment. In http://reviews.llvm.org/D11837#220394, @klimek wrote: > Webkit doesn't break for classes: That's why we need to revert changes in UnwrappedLineParser.cpp. The funny thing with WebKit style is that we don't need to add any logic to deal with it, any style different fr

Re: [PATCH] D11837: Add Qt brace style configuration option.

2015-08-10 Thread Manuel Klimek via cfe-commits
klimek added a comment. Webkit doesn't break for classes: class MyClass { ... }; http://reviews.llvm.org/D11837 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Re: [PATCH] D11837: Add Qt brace style configuration option.

2015-08-10 Thread Roman Kashitsyn via cfe-commits
lifted added a comment. Hooray, I've found the style I need - it's WebKit https://www.webkit.org/coding/coding-style.html So I believe there are other people waiting for the same style as me - https://code.google.com/p/chromium/issues/detail?id=454958 How do you feel about renaming `BS_Qt` -> `

Re: [PATCH] D11837: Add Qt brace style configuration option.

2015-08-10 Thread Roman Kashitsyn via cfe-commits
lifted added a comment. > Hm, the referenced style guide doesn't say anything about namespaces. You're right. Futhermore, it's hard to find any namespaces in qt repos at all - Qt uses a macro for conditional compilation with namespaces. > I also couldn't find anything in the qt source repo (ju

Re: [PATCH] D11837: Add Qt brace style configuration option.

2015-08-10 Thread Manuel Klimek via cfe-commits
klimek added a comment. Hm, the referenced style guide doesn't say anything about namespaces. I also couldn't find anything in the qt source repo (just took a quick look though). Do you have an example of why Qt projects shouldn't just use BS_Linux? http://reviews.llvm.org/D11837 __

Re: [PATCH] D11837: Add Qt brace style configuration option.

2015-08-10 Thread Daniel Jasper via cfe-commits
djasper accepted this revision. djasper added a comment. This revision is now accepted and ready to land. Looks good. Do you have commit access? Comment at: include/clang/Format/Format.h:180 @@ +179,3 @@ +BS_GNU, +/// Like ``Attach``, but break before braces on functions

[PATCH] D11837: Add Qt brace style configuration option.

2015-08-07 Thread Roman Kashitsyn via cfe-commits
lifted created this revision. lifted added a reviewer: djasper. lifted added subscribers: cfe-commits, klimek. Add Qt brace style as described on https://wiki.qt.io/Qt_Coding_Style : * Use attached braces: the opening brace goes on the same line as the start of the statement. If the closing br