Option to remove some extraneous whitespace for suggested fixes?

18 views
Skip to first unread message

Ty Terdan

unread,
Sep 2, 2021, 4:30:43 PM9/2/21
to error-prone-discuss

I made a issue for this: https://github.com/google/error-prone/issues/2500 so alternatively the discussion can happen there...

But the summary is that there are limits to what a code formatter can do, it cannot really know how the developer wants to use whitespace as a grouping mechanism, and it would be nice if error prone had an option to cleanup the "space" left over by removing an UnusedVariable, for example.

That way, the auto-generated fixes won't make your code look like Swiss cheese :)

For context: I am working on some development for a project to auto-generate PRs using Uber's Piranha, which uses error-prone to generate the Java changes.

Thoughts?
Reply all
Reply to author
Forward
0 new messages