Class SizeGreaterThanOrEqualsZero

java.lang.Object
com.google.errorprone.bugpatterns.BugChecker
com.google.errorprone.bugpatterns.SizeGreaterThanOrEqualsZero
All Implemented Interfaces:
BugChecker.BinaryTreeMatcher, Suppressible, Serializable

public class SizeGreaterThanOrEqualsZero extends BugChecker implements BugChecker.BinaryTreeMatcher
Finds instances where one uses Collection#size() >= 0 or T[].length > 0. Those comparisons are always true for non-null objects, where the user likely meant to compare size > 0 instead.
Author:
glorioso@google.com (Nick Glorioso)
See Also: