Skip to main content

lua_types/
arith.rs

1//! Arithmetic operations — used by lvm's arith dispatch.
2
3#[derive(Debug, Clone, Copy, PartialEq, Eq)]
4#[repr(u8)]
5pub enum ArithOp {
6    Add = 0,
7    Sub = 1,
8    Mul = 2,
9    Mod = 3,
10    Pow = 4,
11    Div = 5,
12    Idiv = 6,
13    Band = 7,
14    Bor = 8,
15    Bxor = 9,
16    Shl = 10,
17    Shr = 11,
18    Unm = 12,
19    Bnot = 13,
20}