org.eclipse.xtext.xbase.controlflow
Interface IEarlyExitComputer

All Known Implementing Classes:
DefaultEarlyExitComputer

public interface IEarlyExitComputer

Author:
Sebastian Zarnekow - Initial contribution and API

Nested Class Summary
static class IEarlyExitComputer.ExitPoint
           
 
Method Summary
 java.util.Collection<IEarlyExitComputer.ExitPoint> getExitPoints(XExpression expression)
           
 boolean isEarlyExit(XExpression expression)
          An expression is considered to be left early if all branches end with an explicit termination, e.g. a return or throw expression.
 

Method Detail

isEarlyExit

boolean isEarlyExit(XExpression expression)
An expression is considered to be left early if all branches end with an explicit termination, e.g. a return or throw expression.

Returns:
true if the given expression will definitely exit early.

getExitPoints

java.util.Collection<IEarlyExitComputer.ExitPoint> getExitPoints(XExpression expression)