[clang-apply-replacements] Change cleanup to only happen with --format (#178763)
Cleanup can result in many unrelated changes to the given replacements. This change makes that only apply if the user actually wants clang-apply-replacements to format their code outside of the replacements.
This commit is contained in:
parent
e3c72cf008
commit
0cb14760da
@ -139,7 +139,7 @@ int main(int argc, char **argv) {
|
||||
return 1;
|
||||
|
||||
tooling::ApplyChangesSpec Spec;
|
||||
Spec.Cleanup = true;
|
||||
Spec.Cleanup = DoFormat;
|
||||
Spec.Format = DoFormat ? tooling::ApplyChangesSpec::kAll
|
||||
: tooling::ApplyChangesSpec::kNone;
|
||||
Spec.Style = DoFormat ? FormatStyle : format::getNoStyle();
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user