Skip to content

Conversation

@XinfengZhang
Copy link
Contributor

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 [email protected]

Copy link

@uartie uartie left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

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;
});
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems astyle struggles with lambda expressions. Depending on how it's originally formatted, astyle results can differ. I suppose this one is acceptable, though.

@XinfengZhang
Copy link
Contributor Author

yes , 3.1 is latest astyle version, and was released in 2018. suppose need improvement for C++ new features.

@XinfengZhang XinfengZhang merged commit 25f021c into intel:master Sep 30, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants