mirror of
https://github.com/AleoHQ/leo.git
synced 2024-12-28 12:01:54 +03:00
Merge pull request #136 from AleoHQ/refactor/rename
Rename modules and general housekeeping
This commit is contained in:
commit
0495fc90c3
4
Cargo.lock
generated
4
Cargo.lock
generated
@ -704,7 +704,7 @@ dependencies = [
|
||||
"leo-ast",
|
||||
"leo-gadgets",
|
||||
"leo-input",
|
||||
"leo-types",
|
||||
"leo-typed",
|
||||
"log",
|
||||
"num-bigint",
|
||||
"pest",
|
||||
@ -755,7 +755,7 @@ name = "leo-linter"
|
||||
version = "0.1.0"
|
||||
|
||||
[[package]]
|
||||
name = "leo-types"
|
||||
name = "leo-typed"
|
||||
version = "0.1.0"
|
||||
dependencies = [
|
||||
"criterion",
|
||||
|
@ -13,12 +13,12 @@ name = "leo"
|
||||
path = "leo/main.rs"
|
||||
|
||||
[workspace]
|
||||
members = [ "ast", "compiler", "gadgets", "leo-input", "linter", "types" ]
|
||||
members = [ "ast", "compiler", "gadgets", "input", "linter", "typed" ]
|
||||
|
||||
[dependencies]
|
||||
leo-compiler = { path = "compiler", version = "0.1.0" }
|
||||
leo-gadgets = { path = "gadgets", version = "0.1.0" }
|
||||
leo-input = { path = "leo-input", version = "0.1.0" }
|
||||
leo-input = { path = "input", version = "0.1.0" }
|
||||
|
||||
snarkos-algorithms = { git = "ssh://git@github.com/AleoHQ/snarkOS.git", package = "snarkos-algorithms", default-features = false }
|
||||
snarkos-curves = { git = "ssh://git@github.com/AleoHQ/snarkOS.git", package = "snarkos-curves", default-features = false }
|
||||
|
@ -7,8 +7,8 @@ edition = "2018"
|
||||
[dependencies]
|
||||
leo-ast = { path = "../ast", version = "0.1.0" }
|
||||
leo-gadgets = { path = "../gadgets", version = "0.1.0" }
|
||||
leo-input = { path = "../leo-input", version = "0.1.0" }
|
||||
leo-types = { path = "../types", version = "0.1.0" }
|
||||
leo-input = { path = "../input", version = "0.1.0" }
|
||||
leo-typed = { path = "../typed", version = "0.1.0" }
|
||||
|
||||
snarkos-curves = { git = "ssh://git@github.com/AleoHQ/snarkOS.git", package = "snarkos-curves", default-features = false }
|
||||
snarkos-dpc = { git = "ssh://git@github.com/AleoHQ/snarkOS.git", package = "snarkos-dpc", default-features = false }
|
||||
@ -33,4 +33,4 @@ num-bigint = { version = "0.3" }
|
||||
|
||||
[features]
|
||||
default = []
|
||||
ci_skip = ["leo-ast/ci_skip", "leo-types/ci_skip"]
|
||||
ci_skip = ["leo-ast/ci_skip", "leo-typed/ci_skip"]
|
||||
|
@ -10,7 +10,7 @@ use crate::{
|
||||
};
|
||||
use leo_ast::LeoAst;
|
||||
use leo_input::LeoInputParser;
|
||||
use leo_types::{Input, LeoTypedAst, MainInput, Program};
|
||||
use leo_typed::{Input, LeoTypedAst, MainInput, Program};
|
||||
|
||||
use snarkos_errors::gadgets::SynthesisError;
|
||||
use snarkos_models::{
|
||||
|
@ -9,7 +9,7 @@ use crate::{
|
||||
ImportParser,
|
||||
OutputBytes,
|
||||
};
|
||||
use leo_types::{Input, Program};
|
||||
use leo_typed::{Input, Program};
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -5,7 +5,7 @@ use crate::{
|
||||
value::ConstrainedValue,
|
||||
GroupType,
|
||||
};
|
||||
use leo_types::Variable;
|
||||
use leo_typed::Variable;
|
||||
|
||||
use snarkos_models::curves::{Field, PrimeField};
|
||||
|
||||
|
@ -7,7 +7,7 @@ use crate::{
|
||||
GroupType,
|
||||
ImportParser,
|
||||
};
|
||||
use leo_types::Program;
|
||||
use leo_typed::Program;
|
||||
|
||||
use snarkos_models::curves::{Field, PrimeField};
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
use crate::errors::{AddressError, BooleanError, FieldError, FunctionError, GroupError, IntegerError, ValueError};
|
||||
use leo_types::{Error as FormattedError, Identifier, Span};
|
||||
use leo_typed::{Error as FormattedError, Identifier, Span};
|
||||
|
||||
use snarkos_errors::gadgets::SynthesisError;
|
||||
use std::path::PathBuf;
|
||||
|
@ -9,7 +9,7 @@ use crate::errors::{
|
||||
StatementError,
|
||||
ValueError,
|
||||
};
|
||||
use leo_types::{Error as FormattedError, Span};
|
||||
use leo_typed::{Error as FormattedError, Span};
|
||||
|
||||
use std::path::PathBuf;
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
use leo_ast::ParserError;
|
||||
use leo_types::{Error as FormattedError, Identifier, ImportSymbol, Span};
|
||||
use leo_typed::{Error as FormattedError, Identifier, ImportSymbol, Span};
|
||||
|
||||
use std::{io, path::PathBuf};
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
use crate::errors::ExpressionError;
|
||||
use leo_types::{Error as FormattedError, Span};
|
||||
use leo_typed::{Error as FormattedError, Span};
|
||||
|
||||
use std::path::PathBuf;
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
use leo_types::{Error as FormattedError, Span};
|
||||
use leo_typed::{Error as FormattedError, Span};
|
||||
|
||||
use std::path::PathBuf;
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
use crate::errors::{AddressError, BooleanError, ExpressionError, IntegerError, MacroError, ValueError};
|
||||
use leo_types::{Error as FormattedError, Span, Type};
|
||||
use leo_typed::{Error as FormattedError, Span, Type};
|
||||
|
||||
use std::path::PathBuf;
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
use leo_types::{Error as FormattedError, Span};
|
||||
use leo_typed::{Error as FormattedError, Span};
|
||||
|
||||
use snarkos_errors::{gadgets::SynthesisError, objects::account::AccountError};
|
||||
use std::path::PathBuf;
|
||||
|
@ -1,4 +1,4 @@
|
||||
use leo_types::{Error as FormattedError, Span};
|
||||
use leo_typed::{Error as FormattedError, Span};
|
||||
|
||||
use snarkos_errors::gadgets::SynthesisError;
|
||||
use std::path::PathBuf;
|
||||
|
@ -1,4 +1,4 @@
|
||||
use leo_types::{Error as FormattedError, Span};
|
||||
use leo_typed::{Error as FormattedError, Span};
|
||||
|
||||
use snarkos_errors::gadgets::SynthesisError;
|
||||
use std::path::PathBuf;
|
||||
|
@ -1,4 +1,4 @@
|
||||
use leo_types::{Error as FormattedError, Span};
|
||||
use leo_typed::{Error as FormattedError, Span};
|
||||
|
||||
use snarkos_errors::gadgets::SynthesisError;
|
||||
use std::path::PathBuf;
|
||||
|
@ -1,5 +1,5 @@
|
||||
use leo_gadgets::errors::SignedIntegerError;
|
||||
use leo_types::{error::Error as FormattedError, Span};
|
||||
use leo_typed::{error::Error as FormattedError, Span};
|
||||
|
||||
use snarkos_errors::gadgets::SynthesisError;
|
||||
use std::path::PathBuf;
|
||||
|
@ -1,5 +1,5 @@
|
||||
use crate::errors::{AddressError, BooleanError, FieldError, GroupError, IntegerError};
|
||||
use leo_types::{Error as FormattedError, Span};
|
||||
use leo_typed::{Error as FormattedError, Span};
|
||||
|
||||
use std::path::PathBuf;
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
//! Enforces an arithmetic `+` operator in a resolved Leo program.
|
||||
|
||||
use crate::{errors::ExpressionError, value::ConstrainedValue, GroupType};
|
||||
use leo_types::Span;
|
||||
use leo_typed::Span;
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -1,7 +1,7 @@
|
||||
//! Enforces an arithmetic `/` operator in a resolved Leo program.
|
||||
|
||||
use crate::{errors::ExpressionError, value::ConstrainedValue, GroupType};
|
||||
use leo_types::Span;
|
||||
use leo_typed::Span;
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -1,7 +1,7 @@
|
||||
//! Enforces an arithmetic `*` operator in a resolved Leo program.
|
||||
|
||||
use crate::{errors::ExpressionError, value::ConstrainedValue, GroupType};
|
||||
use leo_types::Span;
|
||||
use leo_typed::Span;
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -1,7 +1,7 @@
|
||||
//! Enforces an arithmetic `**` operator in a resolved Leo program.
|
||||
|
||||
use crate::{errors::ExpressionError, value::ConstrainedValue, GroupType};
|
||||
use leo_types::Span;
|
||||
use leo_typed::Span;
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -1,7 +1,7 @@
|
||||
//! Enforces an arithmetic `-` operator in a resolved Leo program.
|
||||
|
||||
use crate::{errors::ExpressionError, value::ConstrainedValue, GroupType};
|
||||
use leo_types::Span;
|
||||
use leo_typed::Span;
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -1,7 +1,7 @@
|
||||
//! Enforces array access in a compiled Leo program.
|
||||
|
||||
use crate::{errors::ExpressionError, program::ConstrainedProgram, value::ConstrainedValue, GroupType};
|
||||
use leo_types::{Expression, RangeOrExpression, Span, Type};
|
||||
use leo_typed::{Expression, RangeOrExpression, Span, Type};
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -6,7 +6,7 @@ use crate::{
|
||||
value::ConstrainedValue,
|
||||
GroupType,
|
||||
};
|
||||
use leo_types::{Expression, Span, SpreadOrExpression, Type};
|
||||
use leo_typed::{Expression, Span, SpreadOrExpression, Type};
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -1,7 +1,7 @@
|
||||
//! Enforces an array index expression in a compiled Leo program.
|
||||
|
||||
use crate::{errors::ExpressionError, program::ConstrainedProgram, value::ConstrainedValue, GroupType};
|
||||
use leo_types::{Expression, IntegerType, Span, Type};
|
||||
use leo_typed::{Expression, IntegerType, Span, Type};
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -1,7 +1,7 @@
|
||||
//! Enforces a binary expression in a compiled Leo program.
|
||||
|
||||
use crate::{errors::ExpressionError, program::ConstrainedProgram, value::ConstrainedValue, GroupType};
|
||||
use leo_types::{Expression, Span, Type};
|
||||
use leo_typed::{Expression, Span, Type};
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -1,7 +1,7 @@
|
||||
//! Enforces one operand in a binary expression in a compiled Leo program.
|
||||
|
||||
use crate::{errors::ExpressionError, program::ConstrainedProgram, value::ConstrainedValue, GroupType};
|
||||
use leo_types::{Expression, Span, Type};
|
||||
use leo_typed::{Expression, Span, Type};
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -6,7 +6,7 @@ use crate::{
|
||||
value::ConstrainedValue,
|
||||
GroupType,
|
||||
};
|
||||
use leo_types::{Expression, Identifier, Span, Type};
|
||||
use leo_typed::{Expression, Identifier, Span, Type};
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -6,7 +6,7 @@ use crate::{
|
||||
value::{ConstrainedCircuitMember, ConstrainedValue},
|
||||
GroupType,
|
||||
};
|
||||
use leo_types::{CircuitFieldDefinition, CircuitMember, Identifier, Span};
|
||||
use leo_typed::{CircuitFieldDefinition, CircuitMember, Identifier, Span};
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -1,7 +1,7 @@
|
||||
//! Enforces a circuit static access expression in a compiled Leo program.
|
||||
|
||||
use crate::{errors::ExpressionError, program::ConstrainedProgram, value::ConstrainedValue, GroupType};
|
||||
use leo_types::{CircuitMember, Expression, Identifier, Span, Type};
|
||||
use leo_typed::{CircuitMember, Expression, Identifier, Span, Type};
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -1,7 +1,7 @@
|
||||
//! Enforces a conditional expression in a compiled Leo program.
|
||||
|
||||
use crate::{errors::ExpressionError, program::ConstrainedProgram, value::ConstrainedValue, GroupType};
|
||||
use leo_types::{Expression, Span, Type};
|
||||
use leo_typed::{Expression, Span, Type};
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -12,7 +12,7 @@ use crate::{
|
||||
GroupType,
|
||||
Integer,
|
||||
};
|
||||
use leo_types::{Expression, Type};
|
||||
use leo_typed::{Expression, Type};
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -1,7 +1,7 @@
|
||||
//! Enforce a function call expression in a compiled Leo program.
|
||||
|
||||
use crate::{errors::ExpressionError, program::ConstrainedProgram, value::ConstrainedValue, GroupType};
|
||||
use leo_types::{Expression, Span, Type};
|
||||
use leo_typed::{Expression, Span, Type};
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -7,7 +7,7 @@ use crate::{
|
||||
Address,
|
||||
GroupType,
|
||||
};
|
||||
use leo_types::{Identifier, Type};
|
||||
use leo_typed::{Identifier, Type};
|
||||
|
||||
use snarkos_models::curves::{Field, PrimeField};
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
//! Enforces a logical `&&` operator in a resolved Leo program.
|
||||
|
||||
use crate::{errors::BooleanError, value::ConstrainedValue, GroupType};
|
||||
use leo_types::Span;
|
||||
use leo_typed::Span;
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -1,7 +1,7 @@
|
||||
//! Enforces a logical `!` operator in a resolved Leo program.
|
||||
|
||||
use crate::{errors::BooleanError, value::ConstrainedValue, GroupType};
|
||||
use leo_types::Span;
|
||||
use leo_typed::Span;
|
||||
|
||||
use snarkos_models::curves::{Field, PrimeField};
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
//! Enforces a logical `||` operator in a resolved Leo program.
|
||||
|
||||
use crate::{errors::BooleanError, value::ConstrainedValue, GroupType};
|
||||
use leo_types::Span;
|
||||
use leo_typed::Span;
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -1,7 +1,7 @@
|
||||
//! Enforces a relational `==` operator in a resolved Leo program.
|
||||
|
||||
use crate::{errors::ExpressionError, value::ConstrainedValue, GroupType};
|
||||
use leo_types::Span;
|
||||
use leo_typed::Span;
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
use crate::{errors::ExpressionError, value::ConstrainedValue, GroupType};
|
||||
use leo_gadgets::bits::ComparatorGadget;
|
||||
use leo_types::Span;
|
||||
use leo_typed::Span;
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
use crate::{errors::ExpressionError, value::ConstrainedValue, GroupType};
|
||||
use leo_gadgets::bits::ComparatorGadget;
|
||||
use leo_types::Span;
|
||||
use leo_typed::Span;
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
use crate::{errors::ExpressionError, value::ConstrainedValue, GroupType};
|
||||
use leo_gadgets::bits::ComparatorGadget;
|
||||
use leo_types::Span;
|
||||
use leo_typed::Span;
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
use crate::{errors::ExpressionError, value::ConstrainedValue, GroupType};
|
||||
use leo_gadgets::bits::comparator::EvaluateLtGadget;
|
||||
use leo_types::Span;
|
||||
use leo_typed::Span;
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -7,7 +7,7 @@ use crate::{
|
||||
GroupType,
|
||||
};
|
||||
|
||||
use leo_types::{Expression, Function, InputVariable, Span};
|
||||
use leo_typed::{Expression, Function, InputVariable, Span};
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -7,7 +7,7 @@ use crate::{
|
||||
GroupType,
|
||||
};
|
||||
|
||||
use leo_types::{InputValue, Span, Type};
|
||||
use leo_typed::{InputValue, Span, Type};
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
use crate::{errors::FunctionError, program::ConstrainedProgram, value::ConstrainedValue, GroupType};
|
||||
|
||||
use leo_types::{Expression, Type};
|
||||
use leo_typed::{Expression, Type};
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -1,5 +1,5 @@
|
||||
use crate::{errors::FunctionError, ConstrainedCircuitMember, ConstrainedProgram, ConstrainedValue, GroupType};
|
||||
use leo_types::{Identifier, Input};
|
||||
use leo_typed::{Identifier, Input};
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -1,6 +1,6 @@
|
||||
use crate::{errors::FunctionError, ConstrainedCircuitMember, ConstrainedProgram, ConstrainedValue, GroupType};
|
||||
|
||||
use leo_types::{Identifier, InputValue, Parameter};
|
||||
use leo_typed::{Identifier, InputValue, Parameter};
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
gadgets::r1cs::ConstraintSystem,
|
||||
|
@ -14,7 +14,7 @@ use crate::{
|
||||
Integer,
|
||||
};
|
||||
|
||||
use leo_types::{InputValue, Span, Type};
|
||||
use leo_typed::{InputValue, Span, Type};
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -7,7 +7,7 @@ use crate::{
|
||||
OutputBytes,
|
||||
};
|
||||
|
||||
use leo_types::{Expression, Function, Input, InputVariable};
|
||||
use leo_typed::{Expression, Function, Input, InputVariable};
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
use crate::{errors::StatementError, program::ConstrainedProgram, value::ConstrainedValue, GroupType};
|
||||
|
||||
use leo_types::Span;
|
||||
use leo_typed::Span;
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -1,5 +1,5 @@
|
||||
use crate::errors::ImportError;
|
||||
use leo_types::Program;
|
||||
use leo_typed::Program;
|
||||
|
||||
use std::{collections::HashMap, env::current_dir};
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
use crate::{errors::ImportError, ImportParser};
|
||||
use leo_types::{Package, PackageAccess};
|
||||
use leo_typed::{Package, PackageAccess};
|
||||
|
||||
use std::{fs, fs::DirEntry, path::PathBuf};
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
use crate::{errors::ImportError, ImportParser};
|
||||
use leo_ast::LeoAst;
|
||||
use leo_types::{ImportSymbol, Program, Span};
|
||||
use leo_typed::{ImportSymbol, Program, Span};
|
||||
|
||||
use std::{ffi::OsString, fs::DirEntry, path::PathBuf};
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
use crate::{errors::ImportError, imported_symbols::ImportedSymbols, ConstrainedProgram, GroupType, ImportParser};
|
||||
use leo_types::Import;
|
||||
use leo_typed::Import;
|
||||
|
||||
use snarkos_models::curves::{Field, PrimeField};
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
use leo_types::{Import, ImportSymbol, Package, PackageAccess};
|
||||
use leo_typed::{Import, ImportSymbol, Package, PackageAccess};
|
||||
|
||||
/// Stores the the package file name and imported symbol from an import statement
|
||||
#[derive(Debug)]
|
||||
|
@ -1,5 +1,5 @@
|
||||
use crate::{errors::ImportError, new_scope, ConstrainedProgram, ConstrainedValue, GroupType};
|
||||
use leo_types::{ImportSymbol, Program};
|
||||
use leo_typed::{ImportSymbol, Program};
|
||||
|
||||
use snarkos_models::curves::{Field, PrimeField};
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
//! Evaluates a formatted string in a compiled Leo program.
|
||||
|
||||
use crate::{errors::MacroError, program::ConstrainedProgram, GroupType};
|
||||
use leo_types::FormattedString;
|
||||
use leo_typed::FormattedString;
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -1,7 +1,7 @@
|
||||
//! Evaluates a macro in a compiled Leo program.
|
||||
|
||||
use crate::{errors::MacroError, program::ConstrainedProgram, GroupType};
|
||||
use leo_types::{FormattedMacro, MacroName};
|
||||
use leo_typed::{FormattedMacro, MacroName};
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -1,5 +1,5 @@
|
||||
use crate::{errors::OutputBytesError, ConstrainedValue, GroupType, REGISTERS_VARIABLE_NAME};
|
||||
use leo_types::{Parameter, Registers, Span};
|
||||
use leo_typed::{Parameter, Registers, Span};
|
||||
|
||||
use snarkos_models::curves::{Field, PrimeField};
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
//! Enforces an assert equals statement in a compiled Leo program.
|
||||
|
||||
use crate::{errors::StatementError, program::ConstrainedProgram, value::ConstrainedValue, GroupType};
|
||||
use leo_types::Span;
|
||||
use leo_typed::Span;
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -1,7 +1,7 @@
|
||||
//! Enforces an array assignment statement in a compiled Leo program.
|
||||
|
||||
use crate::{errors::StatementError, program::ConstrainedProgram, value::ConstrainedValue, GroupType};
|
||||
use leo_types::{RangeOrExpression, Span};
|
||||
use leo_typed::{RangeOrExpression, Span};
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -7,7 +7,7 @@ use crate::{
|
||||
value::ConstrainedValue,
|
||||
GroupType,
|
||||
};
|
||||
use leo_types::{Assignee, Expression, Span};
|
||||
use leo_typed::{Assignee, Expression, Span};
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -1,7 +1,7 @@
|
||||
//! Resolves assignees in a compiled Leo program.
|
||||
|
||||
use crate::{errors::StatementError, new_scope, program::ConstrainedProgram, value::ConstrainedValue, GroupType};
|
||||
use leo_types::{Assignee, Span};
|
||||
use leo_typed::{Assignee, Span};
|
||||
|
||||
use snarkos_models::curves::{Field, PrimeField};
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
//! Enforces a circuit field assignment statement in a compiled Leo program.
|
||||
|
||||
use crate::{errors::StatementError, program::ConstrainedProgram, value::ConstrainedValue, GroupType};
|
||||
use leo_types::{Identifier, Span};
|
||||
use leo_typed::{Identifier, Span};
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -1,7 +1,7 @@
|
||||
//! Enforces a branch of a conditional or iteration statement in a compiled Leo program.
|
||||
|
||||
use crate::{errors::StatementError, program::ConstrainedProgram, value::ConstrainedValue, GroupType};
|
||||
use leo_types::{Statement, Type};
|
||||
use leo_typed::{Statement, Type};
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -1,7 +1,7 @@
|
||||
//! Methods to enforce constraints on statements in a compiled Leo program.
|
||||
|
||||
use crate::{errors::StatementError, program::ConstrainedProgram, value::ConstrainedValue, GroupType};
|
||||
use leo_types::{ConditionalNestedOrEndStatement, ConditionalStatement, Span, Type};
|
||||
use leo_typed::{ConditionalNestedOrEndStatement, ConditionalStatement, Span, Type};
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -1,7 +1,7 @@
|
||||
//! Enforces a definition statement in a compiled Leo program.
|
||||
|
||||
use crate::{errors::StatementError, program::ConstrainedProgram, GroupType};
|
||||
use leo_types::{Declare, Expression, Span, Variable};
|
||||
use leo_typed::{Declare, Expression, Span, Variable};
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -1,7 +1,7 @@
|
||||
//! Enforces a multiple definition statement in a compiled Leo program.
|
||||
|
||||
use crate::{errors::StatementError, program::ConstrainedProgram, value::ConstrainedValue, GroupType};
|
||||
use leo_types::{Expression, Span, Variable};
|
||||
use leo_typed::{Expression, Span, Variable};
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -8,7 +8,7 @@ use crate::{
|
||||
GroupType,
|
||||
Integer,
|
||||
};
|
||||
use leo_types::{Expression, Identifier, Span, Statement, Type};
|
||||
use leo_typed::{Expression, Identifier, Span, Statement, Type};
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -6,7 +6,7 @@ use crate::{
|
||||
value::ConstrainedValue,
|
||||
GroupType,
|
||||
};
|
||||
use leo_types::{Expression, Span, Type};
|
||||
use leo_typed::{Expression, Span, Type};
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -1,7 +1,7 @@
|
||||
//! Enforces a statement in a compiled Leo program.
|
||||
|
||||
use crate::{errors::StatementError, program::ConstrainedProgram, value::ConstrainedValue, GroupType};
|
||||
use leo_types::{Statement, Type};
|
||||
use leo_typed::{Statement, Type};
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, PrimeField},
|
||||
|
@ -1,5 +1,5 @@
|
||||
use crate::{errors::AddressError, ConstrainedValue, GroupType};
|
||||
use leo_types::{InputValue, Span};
|
||||
use leo_typed::{InputValue, Span};
|
||||
|
||||
use snarkos_dpc::base_dpc::instantiated::Components;
|
||||
use snarkos_errors::gadgets::SynthesisError;
|
||||
|
@ -1,7 +1,7 @@
|
||||
//! Methods to enforce constraints on input boolean values in a resolved Leo program.
|
||||
|
||||
use crate::{errors::BooleanError, value::ConstrainedValue, GroupType};
|
||||
use leo_types::{InputValue, Span};
|
||||
use leo_typed::{InputValue, Span};
|
||||
|
||||
use snarkos_errors::gadgets::SynthesisError;
|
||||
use snarkos_models::{
|
||||
|
@ -1,7 +1,7 @@
|
||||
//! A data type that represents a field value
|
||||
|
||||
use crate::errors::FieldError;
|
||||
use leo_types::Span;
|
||||
use leo_typed::Span;
|
||||
|
||||
use snarkos_errors::gadgets::SynthesisError;
|
||||
use snarkos_models::{
|
||||
|
@ -1,7 +1,7 @@
|
||||
//! Methods to enforce constraints on input field values in a compiled Leo program.
|
||||
|
||||
use crate::{errors::FieldError, value::ConstrainedValue, FieldType, GroupType};
|
||||
use leo_types::{InputValue, Span};
|
||||
use leo_typed::{InputValue, Span};
|
||||
|
||||
use snarkos_errors::gadgets::SynthesisError;
|
||||
use snarkos_models::{
|
||||
|
@ -1,7 +1,7 @@
|
||||
//! A data type that represents members in the group formed by the set of affine points on a curve.
|
||||
|
||||
use crate::errors::GroupError;
|
||||
use leo_types::Span;
|
||||
use leo_typed::Span;
|
||||
|
||||
use snarkos_models::{
|
||||
curves::{Field, One},
|
||||
|
@ -1,7 +1,7 @@
|
||||
//! Methods to enforce constraints on input group values in a Leo program.
|
||||
|
||||
use crate::{errors::GroupError, ConstrainedValue, GroupType};
|
||||
use leo_types::{InputValue, Span};
|
||||
use leo_typed::{InputValue, Span};
|
||||
|
||||
use snarkos_errors::gadgets::SynthesisError;
|
||||
use snarkos_models::{
|
||||
|
@ -1,5 +1,5 @@
|
||||
use crate::{errors::GroupError, GroupType};
|
||||
use leo_types::Span;
|
||||
use leo_typed::Span;
|
||||
|
||||
use snarkos_curves::{
|
||||
edwards_bls12::{EdwardsAffine, EdwardsParameters, Fq},
|
||||
|
@ -1,7 +1,7 @@
|
||||
//! Enforces constraints on an implicit number in a compiled Leo program.
|
||||
|
||||
use crate::{errors::ValueError, value::ConstrainedValue, GroupType};
|
||||
use leo_types::{Span, Type};
|
||||
use leo_typed::{Span, Type};
|
||||
|
||||
use snarkos_models::curves::{Field, PrimeField};
|
||||
|
||||
|
@ -5,7 +5,7 @@ use leo_gadgets::{
|
||||
bits::comparator::{ComparatorGadget, EvaluateLtGadget},
|
||||
signed_integer::*,
|
||||
};
|
||||
use leo_types::{InputValue, IntegerType, Span};
|
||||
use leo_typed::{InputValue, IntegerType, Span};
|
||||
|
||||
use snarkos_errors::gadgets::SynthesisError;
|
||||
use snarkos_models::{
|
||||
|
@ -10,7 +10,7 @@ use crate::{
|
||||
GroupType,
|
||||
Integer,
|
||||
};
|
||||
use leo_types::{Circuit, Function, Identifier, Span, Type};
|
||||
use leo_typed::{Circuit, Function, Identifier, Span, Type};
|
||||
|
||||
use snarkos_errors::gadgets::SynthesisError;
|
||||
use snarkos_models::{
|
||||
|
@ -1,5 +1,5 @@
|
||||
use crate::{assert_satisfied, expect_compiler_error, generate_main_input, parse_program};
|
||||
use leo_types::InputValue;
|
||||
use leo_typed::InputValue;
|
||||
|
||||
static TEST_ADDRESS_1: &'static str = "aleo1qnr4dkkvkgfqph0vzc3y6z2eu975wnpz2925ntjccd5cfqxtyu8sta57j8";
|
||||
static TEST_ADDRESS_2: &'static str = "aleo18qgam03qe483tdrcc3fkqwpp38ehff4a2xma6lu7hams6lfpgcpq3dq05r";
|
||||
|
@ -1,5 +1,5 @@
|
||||
use crate::{assert_satisfied, expect_synthesis_error, generate_main_input, parse_program};
|
||||
use leo_types::InputValue;
|
||||
use leo_typed::InputValue;
|
||||
|
||||
use snarkos_curves::edwards_bls12::Fq;
|
||||
use snarkos_utilities::bytes::ToBytes;
|
||||
|
@ -6,7 +6,7 @@ use crate::{
|
||||
parse_program,
|
||||
parse_program_with_input,
|
||||
};
|
||||
use leo_types::InputValue;
|
||||
use leo_typed::InputValue;
|
||||
|
||||
use snarkos_curves::edwards_bls12::EdwardsAffine;
|
||||
|
||||
|
@ -6,7 +6,7 @@ use crate::{
|
||||
parse_program,
|
||||
};
|
||||
use leo_input::types::{I128Type, IntegerType};
|
||||
use leo_types::InputValue;
|
||||
use leo_typed::InputValue;
|
||||
|
||||
test_int!(Testi128, i128, IntegerType::I128Type(I128Type {}), Int128);
|
||||
|
||||
|
@ -6,7 +6,7 @@ use crate::{
|
||||
parse_program,
|
||||
};
|
||||
use leo_input::types::{I16Type, IntegerType};
|
||||
use leo_types::InputValue;
|
||||
use leo_typed::InputValue;
|
||||
|
||||
test_int!(Testi16, i16, IntegerType::I16Type(I16Type {}), Int16);
|
||||
|
||||
|
@ -6,7 +6,7 @@ use crate::{
|
||||
parse_program,
|
||||
};
|
||||
use leo_input::types::{I32Type, IntegerType};
|
||||
use leo_types::InputValue;
|
||||
use leo_typed::InputValue;
|
||||
|
||||
test_int!(Testi32, i32, IntegerType::I32Type(I32Type {}), Int32);
|
||||
|
||||
|
@ -6,7 +6,7 @@ use crate::{
|
||||
parse_program,
|
||||
};
|
||||
use leo_input::types::{I64Type, IntegerType};
|
||||
use leo_types::InputValue;
|
||||
use leo_typed::InputValue;
|
||||
|
||||
test_int!(Testi64, i64, IntegerType::I64Type(I64Type {}), Int64);
|
||||
|
||||
|
@ -6,7 +6,7 @@ use crate::{
|
||||
parse_program,
|
||||
};
|
||||
use leo_input::types::{I8Type, IntegerType};
|
||||
use leo_types::InputValue;
|
||||
use leo_typed::InputValue;
|
||||
|
||||
test_int!(Testi8, i8, IntegerType::I8Type(I8Type {}), Int8);
|
||||
|
||||
|
@ -6,7 +6,7 @@ use crate::{
|
||||
parse_program,
|
||||
};
|
||||
use leo_input::types::{IntegerType, U128Type};
|
||||
use leo_types::InputValue;
|
||||
use leo_typed::InputValue;
|
||||
|
||||
test_uint!(TestU128, u128, IntegerType::U128Type(U128Type {}), UInt128);
|
||||
|
||||
|
@ -6,7 +6,7 @@ use crate::{
|
||||
parse_program,
|
||||
};
|
||||
use leo_input::types::{IntegerType, U16Type};
|
||||
use leo_types::InputValue;
|
||||
use leo_typed::InputValue;
|
||||
|
||||
test_uint!(TestU16, u16, IntegerType::U16Type(U16Type {}), UInt16);
|
||||
|
||||
|
@ -6,7 +6,7 @@ use crate::{
|
||||
parse_program,
|
||||
};
|
||||
use leo_input::types::{IntegerType, U32Type};
|
||||
use leo_types::InputValue;
|
||||
use leo_typed::InputValue;
|
||||
|
||||
test_uint!(TestU32, u32, IntegerType::U32Type(U32Type {}), UInt32);
|
||||
|
||||
|
@ -6,7 +6,7 @@ use crate::{
|
||||
parse_program,
|
||||
};
|
||||
use leo_input::types::{IntegerType, U64Type};
|
||||
use leo_types::InputValue;
|
||||
use leo_typed::InputValue;
|
||||
|
||||
test_uint!(TestU64, u64, IntegerType::U64Type(U64Type {}), UInt64);
|
||||
|
||||
|
@ -6,7 +6,7 @@ use crate::{
|
||||
parse_program,
|
||||
};
|
||||
use leo_input::types::{IntegerType, U8Type};
|
||||
use leo_types::InputValue;
|
||||
use leo_typed::InputValue;
|
||||
|
||||
test_uint!(TestU8, u8, IntegerType::U8Type(U8Type {}), UInt8);
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
use crate::{assert_satisfied, expect_compiler_error, generate_main_input, parse_program};
|
||||
use leo_types::InputValue;
|
||||
use leo_typed::InputValue;
|
||||
|
||||
#[test]
|
||||
fn test_print() {
|
||||
|
@ -20,7 +20,7 @@ use leo_compiler::{
|
||||
ConstrainedValue,
|
||||
OutputBytes,
|
||||
};
|
||||
use leo_types::{InputValue, MainInput};
|
||||
use leo_typed::{InputValue, MainInput};
|
||||
|
||||
use snarkos_curves::edwards_bls12::Fq;
|
||||
use snarkos_models::gadgets::r1cs::TestConstraintSystem;
|
||||
|
@ -1,5 +1,5 @@
|
||||
use crate::{assert_satisfied, expect_compiler_error, generate_main_input, parse_program};
|
||||
use leo_types::InputValue;
|
||||
use leo_typed::InputValue;
|
||||
|
||||
#[test]
|
||||
fn test_let() {
|
||||
|
@ -8,7 +8,7 @@ use crate::{
|
||||
EdwardsTestCompiler,
|
||||
};
|
||||
use leo_input::types::{IntegerType, U32Type};
|
||||
use leo_types::InputValue;
|
||||
use leo_typed::InputValue;
|
||||
|
||||
#[test]
|
||||
fn test_assert() {
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user