in tools/javac/ApiComparator.java [147:159]
public static Node compare(Api.Module a, Api.Module b) {
Node node;
if (a == null || b == null) {
node = new Node(null, Diff.MODIFIED);
node.compatibility = Compatibility.MAJOR;
node.messages.add(Message.BREAKING_CHANGES);
} else {
node = new Node(null, Diff.NONE);
node.child = compare(a.types, b.types, ApiComparator::compare, node.child);
if (a.hash != b.hash) node.compatibility = Compatibility.PATCH;
}
return node;
}