Reports usages of automatic modules in the requires directive.

An automatic module is unreliable since it can depend on the types on the class path, and its name and exported packages could change if and when it's converted into an explicit module.

Corresponds to -Xlint:requires-automatic and -Xlint:requires-transitive-automatic Javac options. The first option increases awareness of when automatic modules are used. The second warns the authors of a module that they're putting the users of that module at risk by establishing implied readability to an automatic module.

Example:


  //module-info.java
  module org.printer {
    requires transitive drivers.corp.org; // reported in case 'drivers.corp.org' is an automatic module
  }

Use the Highlight only transitive dependencies option to warn only about transitive dependencies.