Explorar el Código

zkas: Remove GreaterThan opcode.

Luther Blissett hace 4 años
padre
commit
2234d6b812
Se han modificado 2 ficheros con 0 adiciones y 9 borrados
  1. 0 5
      src/zkas/opcode.rs
  2. 0 4
      src/zkas/parser.rs

+ 0 - 5
src/zkas/opcode.rs

@@ -37,9 +37,6 @@ pub enum Opcode {
     /// Base field element subtraction
     BaseSub = 0x32,
 
-    /// Base field greater than comparison
-    GreaterThan = 0x33,
-
     /// Constrain a Base field element to a circuit's public input
     ConstrainInstance = 0xf0,
 
@@ -66,7 +63,6 @@ impl Opcode {
             Opcode::BaseAdd => (vec![Type::Base], vec![Type::Base, Type::Base]),
             Opcode::BaseMul => (vec![Type::Base], vec![Type::Base, Type::Base]),
             Opcode::BaseSub => (vec![Type::Base], vec![Type::Base, Type::Base]),
-            Opcode::GreaterThan => (vec![Type::Base], vec![Type::Base, Type::Base]),
             Opcode::ConstrainInstance => (vec![], vec![Type::Base]),
             Opcode::Noop => (vec![], vec![]),
         }
@@ -85,7 +81,6 @@ impl Opcode {
             0x30 => Self::BaseAdd,
             0x31 => Self::BaseMul,
             0x32 => Self::BaseSub,
-            0x33 => Self::GreaterThan,
             0xf0 => Self::ConstrainInstance,
             _ => unimplemented!(),
         }

+ 0 - 4
src/zkas/parser.rs

@@ -636,10 +636,6 @@ Expected `constant/contract/circuit`.",
                         parse_func!(Opcode::BaseSub);
                     }
 
-                    "greater_than" => {
-                        parse_func!(Opcode::GreaterThan);
-                    }
-
                     x => {
                         self.error.abort(
                             &format!("Unimplemented function call `{}`", x),