Skip to content
Catch common Java mistakes as compile-time errors
Java Other
  1. Java 99.9%
  2. Other 0.1%
Branch: master
Clone or download
graememorgan and cgdecker NonCanonicalType: put the types in the description.
Maybe this will make it more explicit what we're talking about.

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=290694611
Latest commit 9fdac7b Jan 21, 2020
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.github ISSUE_TEMPLATE v2 Nov 13, 2018
.idea Check in google-java-format IntelliJ configuration Nov 14, 2018
annotation [maven-release-plugin] prepare for next development iteration Dec 2, 2019
annotations [maven-release-plugin] prepare for next development iteration Dec 2, 2019
check_api Rollback of: Fix a bug in qualifyType. Jan 22, 2020
core NonCanonicalType: put the types in the description. Jan 22, 2020
docgen [maven-release-plugin] prepare for next development iteration Dec 2, 2019
docgen_processor Make sure DocGenProcessor flushes its output stream Jan 16, 2020
docs/bugpattern Try to make exhaustiveness clearer in enum switch examples Jan 18, 2020
examples Update examples for v2.3.4 Dec 6, 2019
refaster [maven-release-plugin] prepare for next development iteration Dec 2, 2019
test_helpers [maven-release-plugin] prepare for next development iteration Dec 2, 2019
third_party/java/auto Initial bazel build Apr 18, 2015
type_annotations [maven-release-plugin] prepare for next development iteration Dec 2, 2019
util Don't delete orphaned bugpattern markdown files. Apr 16, 2018
.gitignore Remove redundant calls to `String.toString()` Jul 6, 2017
.travis.yml Unbreak Travis build Nov 2, 2018
AUTHORS Add String.split check, and make all existing code pass it Dec 21, 2017
CONTRIBUTING.md Add CONTRIBUTING file Dec 18, 2014
COPYING Initial commit. Basic Predicate DSL for matchers, and check for one e… Sep 15, 2011
README.md Use https instead of http May 10, 2018
WORKSPACE Initial bazel build Apr 18, 2015
appveyor.yml Don't notify on appveyor build success Nov 16, 2016
pom.xml Bump maven-compiler-plugin version to 3.8.1. Jan 7, 2020

README.md

Error Prone

Error Prone is a static analysis tool for Java that catches common programming mistakes at compile-time.

public class ShortSet {
  public static void main (String[] args) {
    Set<Short> s = new HashSet<>();
    for (short i = 0; i < 100; i++) {
      s.add(i);
      s.remove(i - 1);
    }
    System.out.println(s.size());
  }
}
error: [CollectionIncompatibleType] Argument 'i - 1' should not be passed to this method;
its type int is not compatible with its collection's type argument Short
      s.remove(i - 1);
              ^
    (see https://errorprone.info/bugpattern/CollectionIncompatibleType)
1 error

Getting Started

Our documentation is at errorprone.info.

Error Prone works with Bazel, Maven, Ant, and Gradle. See our installation instructions for details.

Developing Error Prone

Developing and building Error Prone is documented on the wiki.

Links

You can’t perform that action at this time.