diff --git a/deob-ast/src/main/java/dev/openrs2/deob/ast/transform/BitMaskTransformer.kt b/deob-ast/src/main/java/dev/openrs2/deob/ast/transform/BitMaskTransformer.kt index 388ad71682..ba1802adb3 100644 --- a/deob-ast/src/main/java/dev/openrs2/deob/ast/transform/BitMaskTransformer.kt +++ b/deob-ast/src/main/java/dev/openrs2/deob/ast/transform/BitMaskTransformer.kt @@ -35,7 +35,7 @@ class BitMaskTransformer : Transformer() { mask = when (shiftOp) { BinaryExpr.Operator.SIGNED_RIGHT_SHIFT -> mask shr shamt BinaryExpr.Operator.UNSIGNED_RIGHT_SHIFT -> mask ushr shamt - else -> throw IllegalStateException() + else -> error("Invalid shiftOp") } maskExpr = IntegerLiteralExpr(mask) @@ -45,7 +45,7 @@ class BitMaskTransformer : Transformer() { mask = when (shiftOp) { BinaryExpr.Operator.SIGNED_RIGHT_SHIFT -> mask shr shamt BinaryExpr.Operator.UNSIGNED_RIGHT_SHIFT -> mask ushr shamt - else -> throw IllegalStateException() + else -> error("Invalid shiftOp") } maskExpr = createLong(mask)