diff --git a/compiler/src/expression/relational/ge.rs b/compiler/src/expression/relational/ge.rs index 97fd6dbc1c..11f3edff6a 100644 --- a/compiler/src/expression/relational/ge.rs +++ b/compiler/src/expression/relational/ge.rs @@ -1,7 +1,7 @@ //! Enforces a relational `>=` operator in a resolved Leo program. use crate::{errors::ExpressionError, value::ConstrainedValue, GroupType}; -use leo_gadgets::binary::ComparatorGadget; +use leo_gadgets::bits::ComparatorGadget; use leo_types::Span; use snarkos_models::{ diff --git a/compiler/src/expression/relational/gt.rs b/compiler/src/expression/relational/gt.rs index 198b04716a..003a830dc2 100644 --- a/compiler/src/expression/relational/gt.rs +++ b/compiler/src/expression/relational/gt.rs @@ -1,7 +1,7 @@ //! Enforces a relational `>` operator in a resolved Leo program. use crate::{errors::ExpressionError, value::ConstrainedValue, GroupType}; -use leo_gadgets::binary::ComparatorGadget; +use leo_gadgets::bits::ComparatorGadget; use leo_types::Span; use snarkos_models::{ diff --git a/compiler/src/expression/relational/le.rs b/compiler/src/expression/relational/le.rs index 63a98ceba2..341b53bcc2 100644 --- a/compiler/src/expression/relational/le.rs +++ b/compiler/src/expression/relational/le.rs @@ -1,7 +1,7 @@ //! Enforces a relational `<=` operator in a resolved Leo program. use crate::{errors::ExpressionError, value::ConstrainedValue, GroupType}; -use leo_gadgets::binary::ComparatorGadget; +use leo_gadgets::bits::ComparatorGadget; use leo_types::Span; use snarkos_models::{ diff --git a/compiler/src/expression/relational/lt.rs b/compiler/src/expression/relational/lt.rs index 0f7f15bdce..ad99e52b9d 100644 --- a/compiler/src/expression/relational/lt.rs +++ b/compiler/src/expression/relational/lt.rs @@ -1,7 +1,7 @@ //! Enforces a relational `<` operator in a resolved Leo program. use crate::{errors::ExpressionError, value::ConstrainedValue, GroupType}; -use leo_gadgets::binary::comparator::EvaluateLtGadget; +use leo_gadgets::bits::comparator::EvaluateLtGadget; use leo_types::Span; use snarkos_models::{ diff --git a/compiler/src/value/field/field_type.rs b/compiler/src/value/field/field_type.rs index 8fb78229c5..4000a353c8 100644 --- a/compiler/src/value/field/field_type.rs +++ b/compiler/src/value/field/field_type.rs @@ -1,7 +1,7 @@ //! A data type that represents a field value use crate::errors::FieldError; -use leo_gadgets::binary::{ComparatorGadget, EvaluateLtGadget}; +use leo_gadgets::bits::{ComparatorGadget, EvaluateLtGadget}; use leo_types::Span; use snarkos_errors::gadgets::SynthesisError; diff --git a/compiler/src/value/integer/integer.rs b/compiler/src/value/integer/integer.rs index 139ab9a360..9c3c6bf715 100644 --- a/compiler/src/value/integer/integer.rs +++ b/compiler/src/value/integer/integer.rs @@ -1,7 +1,8 @@ //! Conversion of integer declarations to constraints in Leo. use crate::{errors::IntegerError, integer::macros::IntegerTrait}; use leo_gadgets::{ - binary::comparator::{ComparatorGadget, EvaluateLtGadget}, + arithmetic::*, + bits::comparator::{ComparatorGadget, EvaluateLtGadget}, signed_integer::*, }; use leo_types::{InputValue, IntegerType, Span}; diff --git a/compiler/src/value/integer/macros.rs b/compiler/src/value/integer/macros.rs index 7bf3b765b9..03ae2e728e 100644 --- a/compiler/src/value/integer/macros.rs +++ b/compiler/src/value/integer/macros.rs @@ -1,4 +1,4 @@ -use leo_gadgets::*; +use leo_gadgets::signed_integer::*; use snarkos_models::gadgets::utilities::{ boolean::Boolean, @@ -6,7 +6,7 @@ use snarkos_models::gadgets::utilities::{ }; use std::fmt::Debug; -pub trait IntegerTrait: Sized + Clone + Debug + Add { +pub trait IntegerTrait: Sized + Clone + Debug { fn get_value(&self) -> Option; fn get_bits(&self) -> Vec;