Class Reachability
java.lang.Object
com.google.errorprone.util.Reachability
An implementation of JLS 14.21 reachability.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic boolean
canCompleteNormally
(com.sun.source.tree.CaseTree caseTree) Returns true if the given case tree can complete normally, as defined by JLS 14.21.static boolean
canCompleteNormally
(com.sun.source.tree.StatementTree statement) Returns true if the given statement can complete normally, as defined by JLS 14.21.
-
Constructor Details
-
Reachability
public Reachability()
-
-
Method Details
-
canCompleteNormally
public static boolean canCompleteNormally(com.sun.source.tree.StatementTree statement) Returns true if the given statement can complete normally, as defined by JLS 14.21.An exception is made for
System.exit
, which cannot complete normally in practice. -
canCompleteNormally
public static boolean canCompleteNormally(com.sun.source.tree.CaseTree caseTree) Returns true if the given case tree can complete normally, as defined by JLS 14.21.An exception is made for
System.exit
, which cannot complete normally in practice.
-