unify the code styles using the style_unify script#246
Merged
XinfengZhang merged 2 commits intointel:masterfrom Sep 30, 2021
Merged
unify the code styles using the style_unify script#246XinfengZhang merged 2 commits intointel:masterfrom
XinfengZhang merged 2 commits intointel:masterfrom
Conversation
use astyle to unify the code style copy the style_unify script from https://github.com/intel/libva/blob/master/style_unify Signed-off-by: Carl Zhang <carl.zhang@intel.com>
Signed-off-by: Carl Zhang <carl.zhang@intel.com>
uartie
approved these changes
Sep 22, 2021
uartie
left a comment
There was a problem hiding this comment.
I'm not fond of how some of the C++ code is auto-formatted by astyle, especially the lambdas. Not sure if there are better auto-formatters out there for C++ as I don't use them much.
But, unified code style is generally a good thing... so LGTM.
Comment on lines
129
to
+132
| std::for_each(supported.begin(), supported.end(), | ||
| [](VAConfigAttrib& s) { s.value = 0; }); | ||
| [](VAConfigAttrib & s) { | ||
| s.value = 0; | ||
| }); |
There was a problem hiding this comment.
Seems astyle struggles with lambda expressions. Depending on how it's originally formatted, astyle results can differ. I suppose this one is acceptable, though.
Contributor
Author
|
yes , 3.1 is latest astyle version, and was released in 2018. suppose need improvement for C++ new features. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
use astyle to unify the code style
copy the style_unify script from
https://github.com/intel/libva/blob/master/style_unify
Signed-off-by: Carl Zhang carl.zhang@intel.com