blob: 818a5a1021387a9a2d7f59dd312672c9a10a4738 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
package org.shedlang.compiler.patio.operands;
import org.shedlang.compiler.patio.types.PatioType;
import org.shedlang.compiler.patio.types.PatioTypes;
import org.shedlang.compiler.patio.values.PatioIntValue;
import org.shedlang.compiler.patio.values.PatioIntValueLiteral;
public record PatioIntConst(PatioIntValue value) implements PatioOperandConst {
public static PatioIntConst of(int value) {
return new PatioIntConst(new PatioIntValueLiteral(value));
}
@Override
public PatioType type() {
return PatioTypes.INT;
}
}
|