Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(167)

Unified Diff: tools/android/checkstyle/chromium-style-5.0.xml

Issue 1054203002: Enable NeedsBraces check and fix some checkstyle issues. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Added if checks Created 5 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: tools/android/checkstyle/chromium-style-5.0.xml
diff --git a/tools/android/checkstyle/chromium-style-5.0.xml b/tools/android/checkstyle/chromium-style-5.0.xml
index c43f7794f430506e3332b9fd178520dc2d45f866..9e56dd91a3858513e0336cb4560871c19183694c 100644
--- a/tools/android/checkstyle/chromium-style-5.0.xml
+++ b/tools/android/checkstyle/chromium-style-5.0.xml
@@ -101,8 +101,10 @@
<property name="severity" value="error"/>
</module>
<module name="NeedBraces">
- <property name="severity" value="info"/>
- <property name="tokens" value="LITERAL_FOR, LITERAL_WHILE, LITERAL_DO"/>
+ <message key="needBraces" value="if, for, while, and do require curly braces unless they are single-line statements."/>
+ <property name="severity" value="error"/>
+ <property name="tokens" value="LITERAL_FOR, LITERAL_WHILE, LITERAL_DO, LITERAL_IF"/>
+ <property name="allowSingleLineStatement" value="true"/>
</module>
<module name="EmptyBlock">
<property name="severity" value="error"/>
« no previous file with comments | « content/public/test/android/javatests/src/org/chromium/content/browser/test/util/OrientationChangeObserverCriteria.java ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698