It should be possible to short-circuite functions.
An area of application would for example be boolean operations, such as OR, AND etc.
The function interface shall be extended with a function "boolean isShortCircuitingAllowed()". The AbstractFunction returns "false" by default for this method.
All functions, such as the boolean ones can override this function and return "true".
In the ApplyType (also check other types if an adaption is required) the implementation can be changed so that after each result of a child-element the function is asked if it is already able to determine the result. If no, then the next child is evaluated. Always all results must be passed to the function (not only the actual one). If the result can be determined the calculation is aborted and the result is returned.
All boolean operations would allow short-circuiting, if others are candidates as well should be checked.