Run google-java-format on adb codebase
The initial plan was to have a gradual reformat to preserve the commit history but google-java-format does not allow this. It reformat blindly without taking into account the context. e.g.: Changing one line in a switch-case make this line become unaligned with the unchanged lines since only that line is formatted by google-java-format. This impacts the commit history and its searchability but this is a hit that is worth it since there is no tool to automatically re-format what check-style is reporting (and preventing upload). The alternative is to not use google-java-format and manually fix all the warnings which is not practical. This CL leverages "enhanced switch statement" to reduce the amount of disturbed code. Test: NA Bug: NA No-Typo-Check: Reformat Flag: EXEMPT(reformat) Change-Id: I6abc7b6bbdf46bc9c8e12eecf4a4e0aaf992f274
Loading
Please register or sign in to comment