This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@FunctionalInterface | |
public interface TailCall<T> { | |
static <S> TailCall<S> done(S result) { | |
return new TailCall<S>() { | |
@Override | |
public TailCall<S> apply() { | |
throw new IllegalStateException("Last tailCall does not support apply method"); | |
} | |
@Override |