-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
applied google's clang format #3
Conversation
@toxieainc, are you using a clang format when doing some of the static analysis cleanup? since this project is under the vpinball org, I'd go for whatever is consistent. |
Static analysis is kinda orthogonal to coding guidelines/formatting. For vpinball and pinmame we have no real guidelines/common formatting yet, only 'adapt to guidelines/formatting of surrounding code to be locally consistent'. And i'm against unifying it as an afterthought, as then the blame functionality is always (at least) one more step complicated. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm no big fan of such things, but also don't care much.
One additional comment @jsm174 @mkalkbrenner now that i see the changes in practice. |
I just applied a a coding style that is available out of the box. But for sure we can adjust the clang format file according to our needs. |
But i must admit, that shorter lines have advantages in diff views, especially in three way diffs, even on my ultra wide screen. And I use diff views very often for reviews and especially if I start contributing to something new. |
I have a really hard time with super super super short lines like this one does out of the box as well. |
@jsm174 @toxieainc |
I personally would vote for 120. Plus i personally prefer BreakBeforeBraces Allman (=always do a linebreak before braces), but i know that this setting in general is always debated. At least from my own experience (ranging from tiny open source projects to double-digit-million-line professional projects) this was and is the most common though. If any of these is applied, i guess best would be to revert to pre-PR state and then apply, otherwise some existing new linebreaks may be kept? |
I can do that. So just to confirm:
|
@toxieainc @mkalkbrenner - can you take a look at 640912b I used the source from b300cd6 so immediately before the first apply. I think thats what you were asking to do. |
Looks better, yes, thanks! |
there might be a way to suppress clang format with a tag or something. I will check |
@toxieainc - pushed again with |
Neat, thanks!! |
Before I start to migrate PPUC's threading model and PIN2DMD support to libdmdutil, it would be important to ensure a common coding style.
This PR applies google's coding standard, the one we agreed on for libserum, libzedmd, libppuc, ...
And I changed all line endings to LF to be consistent within the project.