clang-unformat
clang-unformat copied to clipboard
Dulplication of `AfterFunctionDeclarationName`
When I running the unformat, it would generate 2 line with same content:
AfterFunctionDeclarationName: false # edit distance 69
AfterFunctionDeclarationName: false # edit distance 69
In the section of :
SpaceBeforeParensOptions:
AfterControlStatements: false # edit distance 69
AfterForeachMacros: true # did not affect the output
AfterFunctionDeclarationName: false # edit distance 69
AfterFunctionDeclarationName: false # edit distance 69
AfterFunctionDefinitionName: true # did not affect the output
AfterIfMacros: true # did not affect the output
AfterOverloadedOperator: true # did not affect the output
AfterRequiresInClause: true # did not affect the output
AfterRequiresInExpression: true # did not affect the output
BeforeNonEmptyParentheses: false # edit distance 69
It ended up being defined twice here:
https://github.com/alandefreitas/clang-unformat/blob/1b53dd7017e2f2ed171a61a87835e774c578d328/standalone/clang_format.cpp#L476-L481
It ended up being defined twice here:↳
https://github.com/alandefreitas/clang-unformat/blob/1b53dd7017e2f2ed171a61a87835e774c578d328/standalone/clang_format.cpp#L476-L481
Thanks. As I am new to clang-format, a question raised from my mind: is this the normal case or will it be modified in the next release/commit? Or should I delete the duplication by myself?
As I am new to clang-format, a question raised from my mind: is this the normal case or will it be modified in the next release/commit?
clang-format usually includes new options in new releases. If clang-format includes an option but this project doesn't consider it, it'll simply fail to optimize for that option.
On the other hand, if this project tries to optimize for an option but your version of clang-format doesn't support it, then it'll simply ignore the option.
Or should I delete the duplication by myself?
The option should be removed because it can create an output with a duplicated key.
Apart from that, the tool should still work.
This is a very personal project I shared I'm not able to spend much time maintaining it.
Users usually just open small PRs to fix small problems and I merge them.