aboutsummaryrefslogtreecommitdiff
path: root/core/src/main/java/coffee/liz/lambda/eval/EvaluationDepthExceededException.java
blob: 8f2ad2e604e38088d3e3dbed410e6baec0f48b58 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
package coffee.liz.lambda.eval;

import lombok.Getter;

/**
 * Thrown before we get a {@link StackOverflowError}, hopefully.
 */
@Getter
public final class EvaluationDepthExceededException extends RuntimeException {
    private final int maxDepth;

    public EvaluationDepthExceededException(final int maxDepth) {
        super("Evaluation exceeded maximum depth of " + maxDepth);
        this.maxDepth = maxDepth;
    }
}