diff --git a/Cargo.lock b/Cargo.lock
index cdf38c7bed..aaeb4f691d 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -1253,6 +1253,7 @@ dependencies = [
"hex",
"leo-ast",
"leo-core",
+ "leo-core-ast",
"leo-dynamic-check",
"leo-gadgets",
"leo-imports",
@@ -1260,7 +1261,6 @@ dependencies = [
"leo-package",
"leo-state",
"leo-symbol-table",
- "leo-typed",
"num-bigint",
"pest",
"rand",
@@ -1284,8 +1284,8 @@ dependencies = [
name = "leo-core"
version = "1.0.3"
dependencies = [
+ "leo-core-ast",
"leo-gadgets",
- "leo-typed",
"rand",
"rand_xorshift",
"snarkos-curves",
@@ -1296,14 +1296,28 @@ dependencies = [
"thiserror",
]
+[[package]]
+name = "leo-core-ast"
+version = "1.0.3"
+dependencies = [
+ "criterion",
+ "leo-ast",
+ "leo-input",
+ "pest",
+ "serde",
+ "serde_json",
+ "snarkos-errors",
+ "snarkos-models",
+]
+
[[package]]
name = "leo-dynamic-check"
version = "1.0.3"
dependencies = [
"leo-ast",
+ "leo-core-ast",
"leo-imports",
"leo-symbol-table",
- "leo-typed",
"serde",
"serde_json",
"thiserror",
@@ -1327,7 +1341,7 @@ name = "leo-imports"
version = "1.0.3"
dependencies = [
"leo-ast",
- "leo-typed",
+ "leo-core-ast",
"thiserror",
"tracing",
]
@@ -1363,6 +1377,7 @@ dependencies = [
"lazy_static",
"leo-compiler",
"leo-core",
+ "leo-core-ast",
"leo-dynamic-check",
"leo-gadgets",
"leo-imports",
@@ -1414,8 +1429,8 @@ dependencies = [
name = "leo-state"
version = "1.0.3"
dependencies = [
+ "leo-core-ast",
"leo-input",
- "leo-typed",
"rand",
"rand_xorshift",
"snarkos-algorithms",
@@ -1435,26 +1450,12 @@ version = "1.0.3"
dependencies = [
"leo-ast",
"leo-core",
+ "leo-core-ast",
"leo-imports",
- "leo-typed",
"serde",
"thiserror",
]
-[[package]]
-name = "leo-typed"
-version = "1.0.3"
-dependencies = [
- "criterion",
- "leo-ast",
- "leo-input",
- "pest",
- "serde",
- "serde_json",
- "snarkos-errors",
- "snarkos-models",
-]
-
[[package]]
name = "libc"
version = "0.2.76"
diff --git a/Cargo.toml b/Cargo.toml
index 6becd8320c..5abc2a48f8 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -28,6 +28,7 @@ path = "leo/main.rs"
members = [
"ast",
"compiler",
+ "core-ast",
"core",
"dynamic-check",
"gadgets",
@@ -35,7 +36,6 @@ members = [
"input",
"linter",
"package",
- "typed",
"state",
"symbol-table",
]
@@ -48,6 +48,10 @@ version = "1.0.3"
path = "./core"
version = "1.0.1"
+[dependencies.leo-core-ast]
+path = "./core-ast"
+version = "1.0.3"
+
[dependencies.leo-dynamic-check]
path = "./dynamic-check"
version = "1.0.3"
diff --git a/compiler/Cargo.toml b/compiler/Cargo.toml
index 9944c1551a..d115e19902 100644
--- a/compiler/Cargo.toml
+++ b/compiler/Cargo.toml
@@ -45,8 +45,8 @@ version = "1.0.3"
path = "../package"
version = "1.0.3"
-[dependencies.leo-typed]
-path = "../typed"
+[dependencies.leo-core-ast]
+path = "../core-ast"
version = "1.0.3"
[dependencies.leo-state]
@@ -124,4 +124,4 @@ default-features = false
[features]
default = [ ]
-ci_skip = [ "leo-ast/ci_skip", "leo-typed/ci_skip" ]
+ci_skip = [ "leo-ast/ci_skip", "leo-core-ast/ci_skip" ]
diff --git a/compiler/src/compiler.rs b/compiler/src/compiler.rs
index c83e7a5b03..bbd495c111 100644
--- a/compiler/src/compiler.rs
+++ b/compiler/src/compiler.rs
@@ -24,13 +24,13 @@ use crate::{
OutputFile,
};
use leo_ast::LeoAst;
+use leo_core_ast::{Input, LeoCoreAst, MainInput, Program};
use leo_dynamic_check::DynamicCheck;
use leo_imports::ImportParser;
use leo_input::LeoInputParser;
use leo_package::inputs::InputPairs;
use leo_state::verify_local_data_commitment;
use leo_symbol_table::SymbolTable;
-use leo_typed::{Input, LeoCoreAst, MainInput, Program};
use snarkos_dpc::{base_dpc::instantiated::Components, SystemParameters};
use snarkos_errors::gadgets::SynthesisError;
diff --git a/compiler/src/console/assert.rs b/compiler/src/console/assert.rs
index 6e407c215b..9845e51fd4 100644
--- a/compiler/src/console/assert.rs
+++ b/compiler/src/console/assert.rs
@@ -17,7 +17,7 @@
//! Enforces an assert equals statement in a compiled Leo program.
use crate::{errors::ConsoleError, program::ConstrainedProgram, value::ConstrainedValue, GroupType};
-use leo_typed::{Expression, Span, Type};
+use leo_core_ast::{Expression, Span, Type};
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/console/console.rs b/compiler/src/console/console.rs
index af8da4ac25..43023a1294 100644
--- a/compiler/src/console/console.rs
+++ b/compiler/src/console/console.rs
@@ -17,7 +17,7 @@
//! Evaluates a macro in a compiled Leo program.
use crate::{errors::ConsoleError, program::ConstrainedProgram, GroupType};
-use leo_typed::{ConsoleFunction, ConsoleFunctionCall};
+use leo_core_ast::{ConsoleFunction, ConsoleFunctionCall};
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/console/format.rs b/compiler/src/console/format.rs
index 87f2db1fb5..0545539607 100644
--- a/compiler/src/console/format.rs
+++ b/compiler/src/console/format.rs
@@ -17,7 +17,7 @@
//! Evaluates a formatted string in a compiled Leo program.
use crate::{errors::ConsoleError, program::ConstrainedProgram, GroupType};
-use leo_typed::FormattedString;
+use leo_core_ast::FormattedString;
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/constraints/constraints.rs b/compiler/src/constraints/constraints.rs
index 35d2dba2a3..a96339e4f9 100644
--- a/compiler/src/constraints/constraints.rs
+++ b/compiler/src/constraints/constraints.rs
@@ -25,10 +25,10 @@ use crate::{
OutputBytes,
OutputFile,
};
+use leo_core_ast::{Input, Program};
use leo_imports::ImportParser;
use leo_input::LeoInputParser;
use leo_package::inputs::InputPairs;
-use leo_typed::{Input, Program};
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/definition/definition.rs b/compiler/src/definition/definition.rs
index d78aa90aa0..4ed4cbbd6f 100644
--- a/compiler/src/definition/definition.rs
+++ b/compiler/src/definition/definition.rs
@@ -21,7 +21,7 @@ use crate::{
value::ConstrainedValue,
GroupType,
};
-use leo_typed::Identifier;
+use leo_core_ast::Identifier;
use snarkos_models::curves::{Field, PrimeField};
diff --git a/compiler/src/definition/definitions.rs b/compiler/src/definition/definitions.rs
index 4769570352..d15ecd07c2 100644
--- a/compiler/src/definition/definitions.rs
+++ b/compiler/src/definition/definitions.rs
@@ -22,8 +22,8 @@ use crate::{
value::ConstrainedValue,
GroupType,
};
+use leo_core_ast::Program;
use leo_imports::ImportParser;
-use leo_typed::Program;
use snarkos_models::curves::{Field, PrimeField};
diff --git a/compiler/src/errors/console.rs b/compiler/src/errors/console.rs
index 330dd15d52..2d0b636c28 100644
--- a/compiler/src/errors/console.rs
+++ b/compiler/src/errors/console.rs
@@ -15,7 +15,7 @@
// along with the Leo library. If not, see .
use crate::errors::ExpressionError;
-use leo_typed::{Error as FormattedError, Span};
+use leo_core_ast::{Error as FormattedError, Span};
use std::path::Path;
diff --git a/compiler/src/errors/expression.rs b/compiler/src/errors/expression.rs
index bb0ee8577f..705bb5fcd4 100644
--- a/compiler/src/errors/expression.rs
+++ b/compiler/src/errors/expression.rs
@@ -16,7 +16,7 @@
use crate::errors::{AddressError, BooleanError, FieldError, FunctionError, GroupError, IntegerError, ValueError};
use leo_core::LeoCoreError;
-use leo_typed::{Error as FormattedError, Identifier, Span};
+use leo_core_ast::{Error as FormattedError, Identifier, Span};
use snarkos_errors::gadgets::SynthesisError;
use std::path::Path;
diff --git a/compiler/src/errors/function.rs b/compiler/src/errors/function.rs
index f4ccd09231..87919fe0ca 100644
--- a/compiler/src/errors/function.rs
+++ b/compiler/src/errors/function.rs
@@ -25,7 +25,7 @@ use crate::errors::{
StatementError,
ValueError,
};
-use leo_typed::{Error as FormattedError, Span};
+use leo_core_ast::{Error as FormattedError, Span};
use std::path::Path;
diff --git a/compiler/src/errors/import.rs b/compiler/src/errors/import.rs
index b6a6e51180..45f7885828 100644
--- a/compiler/src/errors/import.rs
+++ b/compiler/src/errors/import.rs
@@ -15,7 +15,7 @@
// along with the Leo library. If not, see .
use leo_core::LeoCoreError;
-use leo_typed::{Error as FormattedError, Identifier, ImportSymbol, Span};
+use leo_core_ast::{Error as FormattedError, Identifier, ImportSymbol, Span};
#[derive(Debug, Error)]
pub enum ImportError {
diff --git a/compiler/src/errors/output_bytes.rs b/compiler/src/errors/output_bytes.rs
index d9ef930f35..5cf212572e 100644
--- a/compiler/src/errors/output_bytes.rs
+++ b/compiler/src/errors/output_bytes.rs
@@ -14,7 +14,7 @@
// You should have received a copy of the GNU General Public License
// along with the Leo library. If not, see .
-use leo_typed::{Error as FormattedError, Span};
+use leo_core_ast::{Error as FormattedError, Span};
use std::path::Path;
diff --git a/compiler/src/errors/statement.rs b/compiler/src/errors/statement.rs
index e39dd2e53d..adc04cfc06 100644
--- a/compiler/src/errors/statement.rs
+++ b/compiler/src/errors/statement.rs
@@ -15,7 +15,7 @@
// along with the Leo library. If not, see .
use crate::errors::{AddressError, BooleanError, ConsoleError, ExpressionError, IntegerError, ValueError};
-use leo_typed::{Error as FormattedError, Span, Type};
+use leo_core_ast::{Error as FormattedError, Span, Type};
use std::path::Path;
diff --git a/compiler/src/errors/value/address.rs b/compiler/src/errors/value/address.rs
index 52e84aaccd..1d308d90b1 100644
--- a/compiler/src/errors/value/address.rs
+++ b/compiler/src/errors/value/address.rs
@@ -14,7 +14,7 @@
// You should have received a copy of the GNU General Public License
// along with the Leo library. If not, see .
-use leo_typed::{Error as FormattedError, Span};
+use leo_core_ast::{Error as FormattedError, Span};
use snarkos_errors::{gadgets::SynthesisError, objects::account::AccountError};
use std::path::Path;
diff --git a/compiler/src/errors/value/boolean.rs b/compiler/src/errors/value/boolean.rs
index cafdc4e3f3..897e461a35 100644
--- a/compiler/src/errors/value/boolean.rs
+++ b/compiler/src/errors/value/boolean.rs
@@ -14,7 +14,7 @@
// You should have received a copy of the GNU General Public License
// along with the Leo library. If not, see .
-use leo_typed::{Error as FormattedError, Span};
+use leo_core_ast::{Error as FormattedError, Span};
use snarkos_errors::gadgets::SynthesisError;
use std::path::Path;
diff --git a/compiler/src/errors/value/field.rs b/compiler/src/errors/value/field.rs
index 200749be95..452335bedb 100644
--- a/compiler/src/errors/value/field.rs
+++ b/compiler/src/errors/value/field.rs
@@ -14,7 +14,7 @@
// You should have received a copy of the GNU General Public License
// along with the Leo library. If not, see .
-use leo_typed::{Error as FormattedError, Span};
+use leo_core_ast::{Error as FormattedError, Span};
use snarkos_errors::gadgets::SynthesisError;
use std::path::Path;
diff --git a/compiler/src/errors/value/group.rs b/compiler/src/errors/value/group.rs
index 63c20d5aad..3e7b148654 100644
--- a/compiler/src/errors/value/group.rs
+++ b/compiler/src/errors/value/group.rs
@@ -14,7 +14,7 @@
// You should have received a copy of the GNU General Public License
// along with the Leo library. If not, see .
-use leo_typed::{Error as FormattedError, Span};
+use leo_core_ast::{Error as FormattedError, Span};
use snarkos_errors::gadgets::SynthesisError;
use std::path::Path;
diff --git a/compiler/src/errors/value/integer.rs b/compiler/src/errors/value/integer.rs
index 1133a487f9..4672635cd1 100644
--- a/compiler/src/errors/value/integer.rs
+++ b/compiler/src/errors/value/integer.rs
@@ -14,8 +14,8 @@
// You should have received a copy of the GNU General Public License
// along with the Leo library. If not, see .
+use leo_core_ast::{error::Error as FormattedError, Span};
use leo_gadgets::errors::SignedIntegerError;
-use leo_typed::{error::Error as FormattedError, Span};
use snarkos_errors::gadgets::SynthesisError;
use std::path::Path;
diff --git a/compiler/src/errors/value/value.rs b/compiler/src/errors/value/value.rs
index 8f4a3248fa..fa469919c5 100644
--- a/compiler/src/errors/value/value.rs
+++ b/compiler/src/errors/value/value.rs
@@ -15,7 +15,7 @@
// along with the Leo library. If not, see .
use crate::errors::{AddressError, BooleanError, FieldError, GroupError, IntegerError};
-use leo_typed::{Error as FormattedError, Span};
+use leo_core_ast::{Error as FormattedError, Span};
use std::path::Path;
diff --git a/compiler/src/expression/arithmetic/add.rs b/compiler/src/expression/arithmetic/add.rs
index ba4f09a33a..a52e33756a 100644
--- a/compiler/src/expression/arithmetic/add.rs
+++ b/compiler/src/expression/arithmetic/add.rs
@@ -17,7 +17,7 @@
//! Enforces an arithmetic `+` operator in a resolved Leo program.
use crate::{errors::ExpressionError, value::ConstrainedValue, GroupType};
-use leo_typed::Span;
+use leo_core_ast::Span;
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/expression/arithmetic/div.rs b/compiler/src/expression/arithmetic/div.rs
index daf79b142c..1564b16305 100644
--- a/compiler/src/expression/arithmetic/div.rs
+++ b/compiler/src/expression/arithmetic/div.rs
@@ -17,7 +17,7 @@
//! Enforces an arithmetic `/` operator in a resolved Leo program.
use crate::{errors::ExpressionError, value::ConstrainedValue, GroupType};
-use leo_typed::Span;
+use leo_core_ast::Span;
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/expression/arithmetic/mul.rs b/compiler/src/expression/arithmetic/mul.rs
index 0849d7ccd4..cf3f0bb833 100644
--- a/compiler/src/expression/arithmetic/mul.rs
+++ b/compiler/src/expression/arithmetic/mul.rs
@@ -17,7 +17,7 @@
//! Enforces an arithmetic `*` operator in a resolved Leo program.
use crate::{errors::ExpressionError, value::ConstrainedValue, GroupType};
-use leo_typed::Span;
+use leo_core_ast::Span;
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/expression/arithmetic/negate.rs b/compiler/src/expression/arithmetic/negate.rs
index 2996283ae0..a3318532bd 100644
--- a/compiler/src/expression/arithmetic/negate.rs
+++ b/compiler/src/expression/arithmetic/negate.rs
@@ -17,7 +17,7 @@
//! Enforces a unary negate `-` operator in a resolved Leo program.
use crate::{errors::ExpressionError, value::ConstrainedValue, GroupType};
-use leo_typed::Span;
+use leo_core_ast::Span;
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/expression/arithmetic/pow.rs b/compiler/src/expression/arithmetic/pow.rs
index a416e58ce6..3607d4756c 100644
--- a/compiler/src/expression/arithmetic/pow.rs
+++ b/compiler/src/expression/arithmetic/pow.rs
@@ -17,7 +17,7 @@
//! Enforces an arithmetic `**` operator in a resolved Leo program.
use crate::{errors::ExpressionError, value::ConstrainedValue, GroupType};
-use leo_typed::Span;
+use leo_core_ast::Span;
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/expression/arithmetic/sub.rs b/compiler/src/expression/arithmetic/sub.rs
index bbad8a4262..20502ca597 100644
--- a/compiler/src/expression/arithmetic/sub.rs
+++ b/compiler/src/expression/arithmetic/sub.rs
@@ -17,7 +17,7 @@
//! Enforces an arithmetic `-` operator in a resolved Leo program.
use crate::{errors::ExpressionError, value::ConstrainedValue, GroupType};
-use leo_typed::Span;
+use leo_core_ast::Span;
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/expression/array/access.rs b/compiler/src/expression/array/access.rs
index 7f7b64d7be..c7f7fa827a 100644
--- a/compiler/src/expression/array/access.rs
+++ b/compiler/src/expression/array/access.rs
@@ -17,7 +17,7 @@
//! Enforces array access in a compiled Leo program.
use crate::{errors::ExpressionError, program::ConstrainedProgram, value::ConstrainedValue, GroupType};
-use leo_typed::{Expression, RangeOrExpression, Span, Type};
+use leo_core_ast::{Expression, RangeOrExpression, Span, Type};
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/expression/array/array.rs b/compiler/src/expression/array/array.rs
index 9ff67a1ea7..d5e6f762d8 100644
--- a/compiler/src/expression/array/array.rs
+++ b/compiler/src/expression/array/array.rs
@@ -22,7 +22,7 @@ use crate::{
value::ConstrainedValue,
GroupType,
};
-use leo_typed::{Expression, Span, SpreadOrExpression, Type};
+use leo_core_ast::{Expression, Span, SpreadOrExpression, Type};
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/expression/array/index.rs b/compiler/src/expression/array/index.rs
index 575d4f5103..54b62f169e 100644
--- a/compiler/src/expression/array/index.rs
+++ b/compiler/src/expression/array/index.rs
@@ -17,7 +17,7 @@
//! Enforces an array index expression in a compiled Leo program.
use crate::{errors::ExpressionError, program::ConstrainedProgram, value::ConstrainedValue, GroupType};
-use leo_typed::{Expression, IntegerType, Span, Type};
+use leo_core_ast::{Expression, IntegerType, Span, Type};
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/expression/binary/binary.rs b/compiler/src/expression/binary/binary.rs
index 91d9f98cbd..ee580bfbe8 100644
--- a/compiler/src/expression/binary/binary.rs
+++ b/compiler/src/expression/binary/binary.rs
@@ -17,7 +17,7 @@
//! Enforces a binary expression in a compiled Leo program.
use crate::{errors::ExpressionError, program::ConstrainedProgram, value::ConstrainedValue, GroupType};
-use leo_typed::{Expression, Span, Type};
+use leo_core_ast::{Expression, Span, Type};
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/expression/binary/operand.rs b/compiler/src/expression/binary/operand.rs
index e6ff9530b6..d15156c73a 100644
--- a/compiler/src/expression/binary/operand.rs
+++ b/compiler/src/expression/binary/operand.rs
@@ -17,7 +17,7 @@
//! Enforces one operand in a binary expression in a compiled Leo program.
use crate::{errors::ExpressionError, program::ConstrainedProgram, value::ConstrainedValue, GroupType};
-use leo_typed::{Expression, Span, Type};
+use leo_core_ast::{Expression, Span, Type};
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/expression/circuit/access.rs b/compiler/src/expression/circuit/access.rs
index d0c2f806c2..53d57c51b4 100644
--- a/compiler/src/expression/circuit/access.rs
+++ b/compiler/src/expression/circuit/access.rs
@@ -22,7 +22,7 @@ use crate::{
value::ConstrainedValue,
GroupType,
};
-use leo_typed::{Expression, Identifier, Span, Type};
+use leo_core_ast::{Expression, Identifier, Span, Type};
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/expression/circuit/circuit.rs b/compiler/src/expression/circuit/circuit.rs
index c70ae61107..b1e7b8d421 100644
--- a/compiler/src/expression/circuit/circuit.rs
+++ b/compiler/src/expression/circuit/circuit.rs
@@ -22,7 +22,7 @@ use crate::{
value::{ConstrainedCircuitMember, ConstrainedValue},
GroupType,
};
-use leo_typed::{CircuitMember, CircuitVariableDefinition, Identifier, Span};
+use leo_core_ast::{CircuitMember, CircuitVariableDefinition, Identifier, Span};
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/expression/circuit/static_access.rs b/compiler/src/expression/circuit/static_access.rs
index 1f01fce5dd..7bf3d67df4 100644
--- a/compiler/src/expression/circuit/static_access.rs
+++ b/compiler/src/expression/circuit/static_access.rs
@@ -17,7 +17,7 @@
//! Enforces a circuit static access expression in a compiled Leo program.
use crate::{errors::ExpressionError, program::ConstrainedProgram, value::ConstrainedValue, GroupType};
-use leo_typed::{CircuitMember, Expression, Identifier, Span, Type};
+use leo_core_ast::{CircuitMember, Expression, Identifier, Span, Type};
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/expression/conditional/conditional.rs b/compiler/src/expression/conditional/conditional.rs
index cfae42dbb3..c332b791ba 100644
--- a/compiler/src/expression/conditional/conditional.rs
+++ b/compiler/src/expression/conditional/conditional.rs
@@ -17,7 +17,7 @@
//! Enforces a conditional expression in a compiled Leo program.
use crate::{errors::ExpressionError, program::ConstrainedProgram, value::ConstrainedValue, GroupType};
-use leo_typed::{Expression, Span, Type};
+use leo_core_ast::{Expression, Span, Type};
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/expression/expression.rs b/compiler/src/expression/expression.rs
index 9c0d98c41f..e5b90b0641 100644
--- a/compiler/src/expression/expression.rs
+++ b/compiler/src/expression/expression.rs
@@ -28,7 +28,7 @@ use crate::{
GroupType,
Integer,
};
-use leo_typed::{Expression, Type};
+use leo_core_ast::{Expression, Type};
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/expression/function/core_circuit.rs b/compiler/src/expression/function/core_circuit.rs
index c0314e775f..31e48d8a52 100644
--- a/compiler/src/expression/function/core_circuit.rs
+++ b/compiler/src/expression/function/core_circuit.rs
@@ -17,7 +17,7 @@ use crate::{program::ConstrainedProgram, value::ConstrainedValue, GroupType};
use crate::errors::{ExpressionError, FunctionError};
use leo_core::call_core_circuit;
-use leo_typed::{Expression, Span, Type};
+use leo_core_ast::{Expression, Span, Type};
use snarkos_models::{
curves::{Field, PrimeField},
gadgets::r1cs::ConstraintSystem,
diff --git a/compiler/src/expression/function/function.rs b/compiler/src/expression/function/function.rs
index f24bcc84c6..35b324218b 100644
--- a/compiler/src/expression/function/function.rs
+++ b/compiler/src/expression/function/function.rs
@@ -17,7 +17,7 @@
//! Enforce a function call expression in a compiled Leo program.
use crate::{errors::ExpressionError, new_scope, program::ConstrainedProgram, value::ConstrainedValue, GroupType};
-use leo_typed::{Expression, Span, Type};
+use leo_core_ast::{Expression, Span, Type};
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/expression/identifier/identifier.rs b/compiler/src/expression/identifier/identifier.rs
index f1c8c4662d..9dde05d491 100644
--- a/compiler/src/expression/identifier/identifier.rs
+++ b/compiler/src/expression/identifier/identifier.rs
@@ -23,7 +23,7 @@ use crate::{
Address,
GroupType,
};
-use leo_typed::{Identifier, Type};
+use leo_core_ast::{Identifier, Type};
use snarkos_models::curves::{Field, PrimeField};
diff --git a/compiler/src/expression/logical/and.rs b/compiler/src/expression/logical/and.rs
index 60d6f58eae..cef99fcf7c 100644
--- a/compiler/src/expression/logical/and.rs
+++ b/compiler/src/expression/logical/and.rs
@@ -17,7 +17,7 @@
//! Enforces a logical `&&` operator in a resolved Leo program.
use crate::{errors::BooleanError, value::ConstrainedValue, GroupType};
-use leo_typed::Span;
+use leo_core_ast::Span;
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/expression/logical/not.rs b/compiler/src/expression/logical/not.rs
index 7f23b4651d..cdf84c051a 100644
--- a/compiler/src/expression/logical/not.rs
+++ b/compiler/src/expression/logical/not.rs
@@ -17,7 +17,7 @@
//! Enforces a logical `!` operator in a resolved Leo program.
use crate::{errors::BooleanError, value::ConstrainedValue, GroupType};
-use leo_typed::Span;
+use leo_core_ast::Span;
use snarkos_models::curves::{Field, PrimeField};
diff --git a/compiler/src/expression/logical/or.rs b/compiler/src/expression/logical/or.rs
index 6ba45a3050..1f86254f48 100644
--- a/compiler/src/expression/logical/or.rs
+++ b/compiler/src/expression/logical/or.rs
@@ -17,7 +17,7 @@
//! Enforces a logical `||` operator in a resolved Leo program.
use crate::{errors::BooleanError, value::ConstrainedValue, GroupType};
-use leo_typed::Span;
+use leo_core_ast::Span;
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/expression/relational/eq.rs b/compiler/src/expression/relational/eq.rs
index 69d8d1370f..114a66c65e 100644
--- a/compiler/src/expression/relational/eq.rs
+++ b/compiler/src/expression/relational/eq.rs
@@ -17,7 +17,7 @@
//! Enforces a relational `==` operator in a resolved Leo program.
use crate::{enforce_and, errors::ExpressionError, value::ConstrainedValue, GroupType};
-use leo_typed::Span;
+use leo_core_ast::Span;
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/expression/relational/ge.rs b/compiler/src/expression/relational/ge.rs
index 15e91f9e27..fdd4ed723c 100644
--- a/compiler/src/expression/relational/ge.rs
+++ b/compiler/src/expression/relational/ge.rs
@@ -17,8 +17,8 @@
//! Enforces a relational `>=` operator in a resolved Leo program.
use crate::{errors::ExpressionError, value::ConstrainedValue, GroupType};
+use leo_core_ast::Span;
use leo_gadgets::bits::ComparatorGadget;
-use leo_typed::Span;
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/expression/relational/gt.rs b/compiler/src/expression/relational/gt.rs
index 45351cc999..3939d624c2 100644
--- a/compiler/src/expression/relational/gt.rs
+++ b/compiler/src/expression/relational/gt.rs
@@ -17,8 +17,8 @@
//! Enforces a relational `>` operator in a resolved Leo program.
use crate::{errors::ExpressionError, value::ConstrainedValue, GroupType};
+use leo_core_ast::Span;
use leo_gadgets::bits::ComparatorGadget;
-use leo_typed::Span;
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/expression/relational/le.rs b/compiler/src/expression/relational/le.rs
index 91fbd5e6f9..4849f3d829 100644
--- a/compiler/src/expression/relational/le.rs
+++ b/compiler/src/expression/relational/le.rs
@@ -17,8 +17,8 @@
//! Enforces a relational `<=` operator in a resolved Leo program.
use crate::{errors::ExpressionError, value::ConstrainedValue, GroupType};
+use leo_core_ast::Span;
use leo_gadgets::bits::ComparatorGadget;
-use leo_typed::Span;
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/expression/relational/lt.rs b/compiler/src/expression/relational/lt.rs
index ef9dd01e93..b78d40d638 100644
--- a/compiler/src/expression/relational/lt.rs
+++ b/compiler/src/expression/relational/lt.rs
@@ -17,8 +17,8 @@
//! Enforces a relational `<` operator in a resolved Leo program.
use crate::{errors::ExpressionError, value::ConstrainedValue, GroupType};
+use leo_core_ast::Span;
use leo_gadgets::bits::comparator::EvaluateLtGadget;
-use leo_typed::Span;
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/expression/tuple/access.rs b/compiler/src/expression/tuple/access.rs
index c628ac4243..6d736047ea 100644
--- a/compiler/src/expression/tuple/access.rs
+++ b/compiler/src/expression/tuple/access.rs
@@ -17,7 +17,7 @@
//! Enforces array access in a compiled Leo program.
use crate::{errors::ExpressionError, program::ConstrainedProgram, value::ConstrainedValue, GroupType};
-use leo_typed::{Expression, Span, Type};
+use leo_core_ast::{Expression, Span, Type};
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/expression/tuple/tuple.rs b/compiler/src/expression/tuple/tuple.rs
index 3295fb4fe3..70f9b00dc7 100644
--- a/compiler/src/expression/tuple/tuple.rs
+++ b/compiler/src/expression/tuple/tuple.rs
@@ -17,7 +17,7 @@
//! Enforces an tuple expression in a compiled Leo program.
use crate::{errors::ExpressionError, program::ConstrainedProgram, value::ConstrainedValue, GroupType};
-use leo_typed::{Expression, Span, Type};
+use leo_core_ast::{Expression, Span, Type};
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/function/function.rs b/compiler/src/function/function.rs
index fcce12247f..13be254322 100644
--- a/compiler/src/function/function.rs
+++ b/compiler/src/function/function.rs
@@ -23,7 +23,7 @@ use crate::{
GroupType,
};
-use leo_typed::{Expression, Function, FunctionInput, Span, Type};
+use leo_core_ast::{Expression, Function, FunctionInput, Span, Type};
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/function/input/array.rs b/compiler/src/function/input/array.rs
index 6317fde9c3..881bea90c7 100644
--- a/compiler/src/function/input/array.rs
+++ b/compiler/src/function/input/array.rs
@@ -23,7 +23,7 @@ use crate::{
GroupType,
};
-use leo_typed::{InputValue, Span, Type};
+use leo_core_ast::{InputValue, Span, Type};
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/function/input/function_input.rs b/compiler/src/function/input/function_input.rs
index a588d778c8..1b4e08f7b8 100644
--- a/compiler/src/function/input/function_input.rs
+++ b/compiler/src/function/input/function_input.rs
@@ -18,7 +18,7 @@
use crate::{errors::FunctionError, program::ConstrainedProgram, value::ConstrainedValue, GroupType};
-use leo_typed::{Expression, Type};
+use leo_core_ast::{Expression, Type};
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/function/input/input_keyword.rs b/compiler/src/function/input/input_keyword.rs
index 10025484bd..f657ca854f 100644
--- a/compiler/src/function/input/input_keyword.rs
+++ b/compiler/src/function/input/input_keyword.rs
@@ -15,7 +15,7 @@
// along with the Leo library. If not, see .
use crate::{errors::FunctionError, ConstrainedCircuitMember, ConstrainedProgram, ConstrainedValue, GroupType};
-use leo_typed::{Identifier, Input};
+use leo_core_ast::{Identifier, Input};
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/function/input/input_section.rs b/compiler/src/function/input/input_section.rs
index 96d24bfbd6..2f104e682b 100644
--- a/compiler/src/function/input/input_section.rs
+++ b/compiler/src/function/input/input_section.rs
@@ -16,7 +16,7 @@
use crate::{errors::FunctionError, ConstrainedCircuitMember, ConstrainedProgram, ConstrainedValue, GroupType};
-use leo_typed::{Identifier, InputValue, Parameter};
+use leo_core_ast::{Identifier, InputValue, Parameter};
use snarkos_models::{
curves::{Field, PrimeField},
gadgets::r1cs::ConstraintSystem,
diff --git a/compiler/src/function/input/main_function_input.rs b/compiler/src/function/input/main_function_input.rs
index ef9db4092a..9fe4675810 100644
--- a/compiler/src/function/input/main_function_input.rs
+++ b/compiler/src/function/input/main_function_input.rs
@@ -30,7 +30,7 @@ use crate::{
Integer,
};
-use leo_typed::{InputValue, Span, Type};
+use leo_core_ast::{InputValue, Span, Type};
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/function/input/tuple.rs b/compiler/src/function/input/tuple.rs
index 77ee183309..ab273b6746 100644
--- a/compiler/src/function/input/tuple.rs
+++ b/compiler/src/function/input/tuple.rs
@@ -23,7 +23,7 @@ use crate::{
GroupType,
};
-use leo_typed::{InputValue, Span, Type};
+use leo_core_ast::{InputValue, Span, Type};
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/function/main_function.rs b/compiler/src/function/main_function.rs
index e07aa4a775..c6a89cd85f 100644
--- a/compiler/src/function/main_function.rs
+++ b/compiler/src/function/main_function.rs
@@ -23,7 +23,7 @@ use crate::{
OutputBytes,
};
-use leo_typed::{Expression, Function, FunctionInput, Input};
+use leo_core_ast::{Expression, Function, FunctionInput, Input};
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/function/result/result.rs b/compiler/src/function/result/result.rs
index cceafc612a..04dc3f243a 100644
--- a/compiler/src/function/result/result.rs
+++ b/compiler/src/function/result/result.rs
@@ -18,7 +18,7 @@
use crate::{errors::StatementError, program::ConstrainedProgram, value::ConstrainedValue, GroupType};
-use leo_typed::Span;
+use leo_core_ast::Span;
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/import/parser/import_parser.rs b/compiler/src/import/parser/import_parser.rs
index 7d5bbfce20..b9ad13a87f 100644
--- a/compiler/src/import/parser/import_parser.rs
+++ b/compiler/src/import/parser/import_parser.rs
@@ -15,7 +15,7 @@
// along with the Leo library. If not, see .
use crate::errors::ImportError;
-use leo_typed::{Package, Program};
+use leo_core_ast::{Package, Program};
use std::{collections::HashMap, env::current_dir};
diff --git a/compiler/src/import/store/core_package.rs b/compiler/src/import/store/core_package.rs
index 2357c1d7b6..940b6da46f 100644
--- a/compiler/src/import/store/core_package.rs
+++ b/compiler/src/import/store/core_package.rs
@@ -15,7 +15,7 @@
// along with the Leo library. If not, see .
use crate::{new_scope, ConstrainedProgram, ConstrainedValue, GroupType};
-use leo_typed::Package;
+use leo_core_ast::Package;
use leo_core::{CorePackageList, LeoCoreError};
use snarkos_models::curves::{Field, PrimeField};
diff --git a/compiler/src/import/store/import.rs b/compiler/src/import/store/import.rs
index 094d7c0ca0..9d0501af33 100644
--- a/compiler/src/import/store/import.rs
+++ b/compiler/src/import/store/import.rs
@@ -15,9 +15,9 @@
// along with the Leo library. If not, see .
use crate::{errors::ImportError, ConstrainedProgram, GroupType};
+use leo_core_ast::ImportStatement;
use leo_imports::ImportParser;
use leo_symbol_table::imported_symbols::ImportedSymbols;
-use leo_typed::ImportStatement;
use snarkos_models::curves::{Field, PrimeField};
diff --git a/compiler/src/import/store/symbol.rs b/compiler/src/import/store/symbol.rs
index dfb9244cc2..ad63689c3c 100644
--- a/compiler/src/import/store/symbol.rs
+++ b/compiler/src/import/store/symbol.rs
@@ -15,7 +15,7 @@
// along with the Leo library. If not, see .
use crate::{errors::ImportError, new_scope, ConstrainedProgram, ConstrainedValue, GroupType};
-use leo_typed::{ImportSymbol, Program};
+use leo_core_ast::{ImportSymbol, Program};
use snarkos_models::curves::{Field, PrimeField};
diff --git a/compiler/src/output/output_bytes.rs b/compiler/src/output/output_bytes.rs
index a451c2fc4d..4e8fab7e68 100644
--- a/compiler/src/output/output_bytes.rs
+++ b/compiler/src/output/output_bytes.rs
@@ -15,7 +15,7 @@
// along with the Leo library. If not, see .
use crate::{errors::OutputBytesError, ConstrainedValue, GroupType, REGISTERS_VARIABLE_NAME};
-use leo_typed::{Parameter, Registers, Span};
+use leo_core_ast::{Parameter, Registers, Span};
use snarkos_models::curves::{Field, PrimeField};
diff --git a/compiler/src/statement/assign/array.rs b/compiler/src/statement/assign/array.rs
index c282ca0fee..222913893d 100644
--- a/compiler/src/statement/assign/array.rs
+++ b/compiler/src/statement/assign/array.rs
@@ -17,7 +17,7 @@
//! Enforces an array assignment statement in a compiled Leo program.
use crate::{errors::StatementError, program::ConstrainedProgram, value::ConstrainedValue, GroupType};
-use leo_typed::{RangeOrExpression, Span};
+use leo_core_ast::{RangeOrExpression, Span};
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/statement/assign/assign.rs b/compiler/src/statement/assign/assign.rs
index 8fb78c6f02..f757fefab3 100644
--- a/compiler/src/statement/assign/assign.rs
+++ b/compiler/src/statement/assign/assign.rs
@@ -24,7 +24,7 @@ use crate::{
value::ConstrainedValue,
GroupType,
};
-use leo_typed::{Assignee, AssigneeAccess, Expression, Span};
+use leo_core_ast::{Assignee, AssigneeAccess, Expression, Span};
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/statement/assign/assignee.rs b/compiler/src/statement/assign/assignee.rs
index 3a15996cdd..217a055892 100644
--- a/compiler/src/statement/assign/assignee.rs
+++ b/compiler/src/statement/assign/assignee.rs
@@ -17,7 +17,7 @@
//! Resolves assignees in a compiled Leo program.
use crate::{errors::StatementError, new_scope, program::ConstrainedProgram, value::ConstrainedValue, GroupType};
-use leo_typed::{Assignee, Span};
+use leo_core_ast::{Assignee, Span};
use snarkos_models::curves::{Field, PrimeField};
diff --git a/compiler/src/statement/assign/circuit_variable.rs b/compiler/src/statement/assign/circuit_variable.rs
index 2aea133662..1362849875 100644
--- a/compiler/src/statement/assign/circuit_variable.rs
+++ b/compiler/src/statement/assign/circuit_variable.rs
@@ -17,7 +17,7 @@
//! Enforces a circuit variable assignment statement in a compiled Leo program.
use crate::{errors::StatementError, program::ConstrainedProgram, value::ConstrainedValue, GroupType};
-use leo_typed::{Identifier, Span};
+use leo_core_ast::{Identifier, Span};
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/statement/assign/tuple.rs b/compiler/src/statement/assign/tuple.rs
index a8a8a0a7fb..307aef4d87 100644
--- a/compiler/src/statement/assign/tuple.rs
+++ b/compiler/src/statement/assign/tuple.rs
@@ -17,7 +17,7 @@
//! Enforces a tuple assignment statement in a compiled Leo program.
use crate::{errors::StatementError, program::ConstrainedProgram, value::ConstrainedValue, GroupType};
-use leo_typed::Span;
+use leo_core_ast::Span;
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/statement/branch/branch.rs b/compiler/src/statement/branch/branch.rs
index ddb6e91838..96edc1aec9 100644
--- a/compiler/src/statement/branch/branch.rs
+++ b/compiler/src/statement/branch/branch.rs
@@ -17,7 +17,7 @@
//! Enforces a branch of a conditional or iteration statement in a compiled Leo program.
use crate::{program::ConstrainedProgram, GroupType, IndicatorAndConstrainedValue, StatementResult};
-use leo_typed::{Statement, Type};
+use leo_core_ast::{Statement, Type};
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/statement/conditional/conditional.rs b/compiler/src/statement/conditional/conditional.rs
index db83d57ffb..ccc86141f9 100644
--- a/compiler/src/statement/conditional/conditional.rs
+++ b/compiler/src/statement/conditional/conditional.rs
@@ -24,7 +24,7 @@ use crate::{
IndicatorAndConstrainedValue,
StatementResult,
};
-use leo_typed::{ConditionalNestedOrEndStatement, ConditionalStatement, Span, Type};
+use leo_core_ast::{ConditionalNestedOrEndStatement, ConditionalStatement, Span, Type};
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/statement/definition/definition.rs b/compiler/src/statement/definition/definition.rs
index f2642883ba..4de710251c 100644
--- a/compiler/src/statement/definition/definition.rs
+++ b/compiler/src/statement/definition/definition.rs
@@ -17,7 +17,7 @@
//! Enforces a definition statement in a compiled Leo program.
use crate::{errors::StatementError, program::ConstrainedProgram, ConstrainedValue, GroupType};
-use leo_typed::{Declare, Expression, Span, VariableName, Variables};
+use leo_core_ast::{Declare, Expression, Span, VariableName, Variables};
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/statement/iteration/iteration.rs b/compiler/src/statement/iteration/iteration.rs
index f9c658ad1e..bdf7f43f97 100644
--- a/compiler/src/statement/iteration/iteration.rs
+++ b/compiler/src/statement/iteration/iteration.rs
@@ -25,7 +25,7 @@ use crate::{
Integer,
StatementResult,
};
-use leo_typed::{Expression, Identifier, Span, Statement, Type};
+use leo_core_ast::{Expression, Identifier, Span, Statement, Type};
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/statement/return_/return_.rs b/compiler/src/statement/return_/return_.rs
index 4c1cb083c6..85f7e6caaf 100644
--- a/compiler/src/statement/return_/return_.rs
+++ b/compiler/src/statement/return_/return_.rs
@@ -17,7 +17,7 @@
//! Enforces a return statement in a compiled Leo program.
use crate::{errors::StatementError, program::ConstrainedProgram, value::ConstrainedValue, GroupType};
-use leo_typed::{Expression, Span, Type};
+use leo_core_ast::{Expression, Span, Type};
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/statement/statement.rs b/compiler/src/statement/statement.rs
index 8ceffe9e7f..1c23bee4dd 100644
--- a/compiler/src/statement/statement.rs
+++ b/compiler/src/statement/statement.rs
@@ -17,7 +17,7 @@
//! Enforces a statement in a compiled Leo program.
use crate::{errors::StatementError, program::ConstrainedProgram, value::ConstrainedValue, GroupType};
-use leo_typed::{Statement, Type};
+use leo_core_ast::{Statement, Type};
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/compiler/src/value/address/address.rs b/compiler/src/value/address/address.rs
index e385138402..3bbdda41cd 100644
--- a/compiler/src/value/address/address.rs
+++ b/compiler/src/value/address/address.rs
@@ -15,7 +15,7 @@
// along with the Leo library. If not, see .
use crate::{errors::AddressError, ConstrainedValue, GroupType};
-use leo_typed::{InputValue, Span};
+use leo_core_ast::{InputValue, Span};
use snarkos_dpc::base_dpc::instantiated::Components;
use snarkos_errors::gadgets::SynthesisError;
diff --git a/compiler/src/value/boolean/input.rs b/compiler/src/value/boolean/input.rs
index 9b712b95d6..25a9b915f2 100644
--- a/compiler/src/value/boolean/input.rs
+++ b/compiler/src/value/boolean/input.rs
@@ -17,7 +17,7 @@
//! Methods to enforce constraints on input boolean values in a resolved Leo program.
use crate::{errors::BooleanError, value::ConstrainedValue, GroupType};
-use leo_typed::{InputValue, Span};
+use leo_core_ast::{InputValue, Span};
use snarkos_errors::gadgets::SynthesisError;
use snarkos_models::{
diff --git a/compiler/src/value/field/field_type.rs b/compiler/src/value/field/field_type.rs
index c22bed7600..f2423ff0e3 100644
--- a/compiler/src/value/field/field_type.rs
+++ b/compiler/src/value/field/field_type.rs
@@ -17,7 +17,7 @@
//! A data type that represents a field value
use crate::errors::FieldError;
-use leo_typed::Span;
+use leo_core_ast::Span;
use snarkos_errors::gadgets::SynthesisError;
use snarkos_models::{
diff --git a/compiler/src/value/field/input.rs b/compiler/src/value/field/input.rs
index 34d14d0f75..6cf4339192 100644
--- a/compiler/src/value/field/input.rs
+++ b/compiler/src/value/field/input.rs
@@ -17,7 +17,7 @@
//! Methods to enforce constraints on input field values in a compiled Leo program.
use crate::{errors::FieldError, value::ConstrainedValue, FieldType, GroupType};
-use leo_typed::{InputValue, Span};
+use leo_core_ast::{InputValue, Span};
use snarkos_errors::gadgets::SynthesisError;
use snarkos_models::{
diff --git a/compiler/src/value/group/group_type.rs b/compiler/src/value/group/group_type.rs
index 3dc2a0250d..3521abecee 100644
--- a/compiler/src/value/group/group_type.rs
+++ b/compiler/src/value/group/group_type.rs
@@ -17,7 +17,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_typed::{GroupValue, Span};
+use leo_core_ast::{GroupValue, Span};
use snarkos_models::{
curves::{Field, One},
diff --git a/compiler/src/value/group/input.rs b/compiler/src/value/group/input.rs
index 293ffd92a0..a4cdae715c 100644
--- a/compiler/src/value/group/input.rs
+++ b/compiler/src/value/group/input.rs
@@ -17,7 +17,7 @@
//! Methods to enforce constraints on input group values in a Leo program.
use crate::{errors::GroupError, ConstrainedValue, GroupType};
-use leo_typed::{GroupValue, InputValue, Span};
+use leo_core_ast::{GroupValue, InputValue, Span};
use snarkos_errors::gadgets::SynthesisError;
use snarkos_models::{
diff --git a/compiler/src/value/group/targets/edwards_bls12.rs b/compiler/src/value/group/targets/edwards_bls12.rs
index c146e04564..66cbc8cae3 100644
--- a/compiler/src/value/group/targets/edwards_bls12.rs
+++ b/compiler/src/value/group/targets/edwards_bls12.rs
@@ -15,7 +15,7 @@
// along with the Leo library. If not, see .
use crate::{errors::GroupError, GroupType};
-use leo_typed::{GroupCoordinate, GroupTuple, GroupValue, Span};
+use leo_core_ast::{GroupCoordinate, GroupTuple, GroupValue, Span};
use snarkos_curves::{
edwards_bls12::{EdwardsAffine, EdwardsParameters, Fq},
diff --git a/compiler/src/value/implicit/implicit.rs b/compiler/src/value/implicit/implicit.rs
index 27b6cb76c6..b838a4a689 100644
--- a/compiler/src/value/implicit/implicit.rs
+++ b/compiler/src/value/implicit/implicit.rs
@@ -17,7 +17,7 @@
//! Enforces constraints on an implicit number in a compiled Leo program.
use crate::{errors::ValueError, value::ConstrainedValue, GroupType};
-use leo_typed::{Span, Type};
+use leo_core_ast::{Span, Type};
use snarkos_models::curves::{Field, PrimeField};
diff --git a/compiler/src/value/integer/integer.rs b/compiler/src/value/integer/integer.rs
index 0384248624..f859caf69a 100644
--- a/compiler/src/value/integer/integer.rs
+++ b/compiler/src/value/integer/integer.rs
@@ -16,12 +16,12 @@
//! Conversion of integer declarations to constraints in Leo.
use crate::{errors::IntegerError, IntegerTrait};
+use leo_core_ast::{InputValue, IntegerType, Span};
use leo_gadgets::{
arithmetic::*,
bits::comparator::{ComparatorGadget, EvaluateLtGadget},
signed_integer::*,
};
-use leo_typed::{InputValue, IntegerType, Span};
use snarkos_errors::gadgets::SynthesisError;
use snarkos_models::{
diff --git a/compiler/src/value/value.rs b/compiler/src/value/value.rs
index de2d80f524..cf194e1460 100644
--- a/compiler/src/value/value.rs
+++ b/compiler/src/value/value.rs
@@ -27,7 +27,7 @@ use crate::{
Integer,
};
use leo_core::Value;
-use leo_typed::{Circuit, Function, GroupValue, Identifier, Span, Type};
+use leo_core_ast::{Circuit, Function, GroupValue, Identifier, Span, Type};
use snarkos_errors::gadgets::SynthesisError;
use snarkos_models::{
diff --git a/compiler/tests/address/mod.rs b/compiler/tests/address/mod.rs
index c3c2167cd4..fac98eb643 100644
--- a/compiler/tests/address/mod.rs
+++ b/compiler/tests/address/mod.rs
@@ -15,7 +15,7 @@
// along with the Leo library. If not, see .
use crate::{assert_satisfied, expect_compiler_error, generate_main_input, parse_program};
-use leo_typed::InputValue;
+use leo_core_ast::InputValue;
static TEST_ADDRESS_1: &str = "aleo1qnr4dkkvkgfqph0vzc3y6z2eu975wnpz2925ntjccd5cfqxtyu8sta57j8";
static TEST_ADDRESS_2: &str = "aleo18qgam03qe483tdrcc3fkqwpp38ehff4a2xma6lu7hams6lfpgcpq3dq05r";
diff --git a/compiler/tests/console/mod.rs b/compiler/tests/console/mod.rs
index 2716f815a5..73f0b41fe6 100644
--- a/compiler/tests/console/mod.rs
+++ b/compiler/tests/console/mod.rs
@@ -15,7 +15,7 @@
// along with the Leo library. If not, see .
use crate::{assert_satisfied, expect_compiler_error, generate_main_input, parse_program};
-use leo_typed::InputValue;
+use leo_core_ast::InputValue;
#[test]
fn test_log() {
diff --git a/compiler/tests/core/packages/unstable/blake2s/mod.rs b/compiler/tests/core/packages/unstable/blake2s/mod.rs
index 83ec7d15a1..3d367dcf89 100644
--- a/compiler/tests/core/packages/unstable/blake2s/mod.rs
+++ b/compiler/tests/core/packages/unstable/blake2s/mod.rs
@@ -23,8 +23,8 @@ use crate::{
parse_program_with_input,
};
+use leo_core_ast::InputValue;
use leo_input::types::{IntegerType, U8Type, UnsignedIntegerType};
-use leo_typed::InputValue;
use rand::{Rng, SeedableRng};
use rand_xorshift::XorShiftRng;
use snarkos_algorithms::prf::blake2s::Blake2s as B2SPRF;
diff --git a/compiler/tests/field/mod.rs b/compiler/tests/field/mod.rs
index a57817b2f7..706c5bd70d 100644
--- a/compiler/tests/field/mod.rs
+++ b/compiler/tests/field/mod.rs
@@ -15,7 +15,7 @@
// along with the Leo library. If not, see .
use crate::{assert_satisfied, expect_compiler_error, generate_main_input, parse_program};
-use leo_typed::InputValue;
+use leo_core_ast::InputValue;
use snarkos_curves::edwards_bls12::Fq;
use snarkos_utilities::bytes::ToBytes;
diff --git a/compiler/tests/group/mod.rs b/compiler/tests/group/mod.rs
index 7606a738d3..901597806f 100644
--- a/compiler/tests/group/mod.rs
+++ b/compiler/tests/group/mod.rs
@@ -15,15 +15,10 @@
// along with the Leo library. If not, see .
use crate::{
- assert_satisfied,
- expect_compiler_error,
- expect_synthesis_error,
- field::field_to_decimal_string,
- generate_main_input,
- parse_program,
- parse_program_with_input,
+ assert_satisfied, expect_compiler_error, expect_synthesis_error, field::field_to_decimal_string,
+ generate_main_input, parse_program, parse_program_with_input,
};
-use leo_typed::{GroupCoordinate, GroupTuple, GroupValue, InputValue, Span};
+use leo_core_ast::{GroupCoordinate, GroupTuple, GroupValue, InputValue, Span};
use snarkos_curves::edwards_bls12::EdwardsAffine;
diff --git a/compiler/tests/integers/i128/mod.rs b/compiler/tests/integers/i128/mod.rs
index 9139cd5ec4..8f4023a99a 100644
--- a/compiler/tests/integers/i128/mod.rs
+++ b/compiler/tests/integers/i128/mod.rs
@@ -21,8 +21,8 @@ use crate::{
integers::{expect_computation_error, expect_parsing_error, IntegerTester},
parse_program,
};
+use leo_core_ast::InputValue;
use leo_input::types::{I128Type, IntegerType, SignedIntegerType};
-use leo_typed::InputValue;
test_int!(
TestI128,
diff --git a/compiler/tests/integers/i16/mod.rs b/compiler/tests/integers/i16/mod.rs
index 9348352276..73519f487a 100644
--- a/compiler/tests/integers/i16/mod.rs
+++ b/compiler/tests/integers/i16/mod.rs
@@ -21,8 +21,8 @@ use crate::{
integers::{expect_computation_error, expect_parsing_error, IntegerTester},
parse_program,
};
+use leo_core_ast::InputValue;
use leo_input::types::{I16Type, IntegerType, SignedIntegerType};
-use leo_typed::InputValue;
test_int!(
TestI16,
diff --git a/compiler/tests/integers/i32/mod.rs b/compiler/tests/integers/i32/mod.rs
index 73e4e4a2f5..6c18449559 100644
--- a/compiler/tests/integers/i32/mod.rs
+++ b/compiler/tests/integers/i32/mod.rs
@@ -21,8 +21,8 @@ use crate::{
integers::{expect_computation_error, expect_parsing_error, IntegerTester},
parse_program,
};
+use leo_core_ast::InputValue;
use leo_input::types::{I32Type, IntegerType, SignedIntegerType};
-use leo_typed::InputValue;
test_int!(
TestI32,
diff --git a/compiler/tests/integers/i64/mod.rs b/compiler/tests/integers/i64/mod.rs
index 218842b3ad..1d61ef1bca 100644
--- a/compiler/tests/integers/i64/mod.rs
+++ b/compiler/tests/integers/i64/mod.rs
@@ -21,8 +21,8 @@ use crate::{
integers::{expect_computation_error, expect_parsing_error, IntegerTester},
parse_program,
};
+use leo_core_ast::InputValue;
use leo_input::types::{I64Type, IntegerType, SignedIntegerType};
-use leo_typed::InputValue;
test_int!(
TestI64,
diff --git a/compiler/tests/integers/i8/mod.rs b/compiler/tests/integers/i8/mod.rs
index a17896c05d..6a8f535b72 100644
--- a/compiler/tests/integers/i8/mod.rs
+++ b/compiler/tests/integers/i8/mod.rs
@@ -21,8 +21,8 @@ use crate::{
integers::{expect_computation_error, expect_parsing_error, IntegerTester},
parse_program,
};
+use leo_core_ast::InputValue;
use leo_input::types::{I8Type, IntegerType, SignedIntegerType};
-use leo_typed::InputValue;
test_int!(
TestI8,
diff --git a/compiler/tests/integers/u128/mod.rs b/compiler/tests/integers/u128/mod.rs
index e5fd5f2d44..84e72e27c7 100644
--- a/compiler/tests/integers/u128/mod.rs
+++ b/compiler/tests/integers/u128/mod.rs
@@ -21,8 +21,8 @@ use crate::{
integers::{expect_parsing_error, IntegerTester},
parse_program,
};
+use leo_core_ast::InputValue;
use leo_input::types::{IntegerType, U128Type, UnsignedIntegerType};
-use leo_typed::InputValue;
test_uint!(
TestU128,
diff --git a/compiler/tests/integers/u16/mod.rs b/compiler/tests/integers/u16/mod.rs
index 1c2c45889b..c6a3388505 100644
--- a/compiler/tests/integers/u16/mod.rs
+++ b/compiler/tests/integers/u16/mod.rs
@@ -21,8 +21,8 @@ use crate::{
integers::{expect_parsing_error, IntegerTester},
parse_program,
};
+use leo_core_ast::InputValue;
use leo_input::types::{IntegerType, U16Type, UnsignedIntegerType};
-use leo_typed::InputValue;
test_uint!(
TestU16,
diff --git a/compiler/tests/integers/u32/mod.rs b/compiler/tests/integers/u32/mod.rs
index 3ffb792f4d..fc4cd16eb8 100644
--- a/compiler/tests/integers/u32/mod.rs
+++ b/compiler/tests/integers/u32/mod.rs
@@ -21,8 +21,8 @@ use crate::{
integers::{expect_parsing_error, IntegerTester},
parse_program,
};
+use leo_core_ast::InputValue;
use leo_input::types::{IntegerType, U32Type, UnsignedIntegerType};
-use leo_typed::InputValue;
test_uint!(
TestU32,
diff --git a/compiler/tests/integers/u64/mod.rs b/compiler/tests/integers/u64/mod.rs
index 06fad4baa3..bd18a0fd09 100644
--- a/compiler/tests/integers/u64/mod.rs
+++ b/compiler/tests/integers/u64/mod.rs
@@ -21,8 +21,8 @@ use crate::{
integers::{expect_parsing_error, IntegerTester},
parse_program,
};
+use leo_core_ast::InputValue;
use leo_input::types::{IntegerType, U64Type, UnsignedIntegerType};
-use leo_typed::InputValue;
test_uint!(
TestU64,
diff --git a/compiler/tests/integers/u8/mod.rs b/compiler/tests/integers/u8/mod.rs
index 335e4146ff..f9d6a5e1bb 100644
--- a/compiler/tests/integers/u8/mod.rs
+++ b/compiler/tests/integers/u8/mod.rs
@@ -21,8 +21,8 @@ use crate::{
integers::{expect_parsing_error, IntegerTester},
parse_program,
};
+use leo_core_ast::InputValue;
use leo_input::types::{IntegerType, U8Type, UnsignedIntegerType};
-use leo_typed::InputValue;
test_uint!(
TestU8,
diff --git a/compiler/tests/mod.rs b/compiler/tests/mod.rs
index e34d048dbb..1d9bbc69c2 100644
--- a/compiler/tests/mod.rs
+++ b/compiler/tests/mod.rs
@@ -42,8 +42,8 @@ use leo_compiler::{
ConstrainedValue,
OutputBytes,
};
+use leo_core_ast::{InputValue, MainInput};
use leo_input::types::{IntegerType, U32Type, UnsignedIntegerType};
-use leo_typed::{InputValue, MainInput};
use snarkos_curves::edwards_bls12::Fq;
use snarkos_models::gadgets::r1cs::TestConstraintSystem;
diff --git a/compiler/tests/mutability/mod.rs b/compiler/tests/mutability/mod.rs
index c36cd10b14..60b3d31ec8 100644
--- a/compiler/tests/mutability/mod.rs
+++ b/compiler/tests/mutability/mod.rs
@@ -15,7 +15,7 @@
// along with the Leo library. If not, see .
use crate::{assert_satisfied, expect_compiler_error, expect_dynamic_check_error, generate_main_input, parse_program};
-use leo_typed::InputValue;
+use leo_core_ast::InputValue;
#[test]
fn test_let() {
diff --git a/compiler/tests/statements/conditional/mod.rs b/compiler/tests/statements/conditional/mod.rs
index 9b6ae2fe2b..d6b5ab8c14 100644
--- a/compiler/tests/statements/conditional/mod.rs
+++ b/compiler/tests/statements/conditional/mod.rs
@@ -24,7 +24,7 @@ use crate::{
parse_program_with_input,
EdwardsTestCompiler,
};
-use leo_typed::InputValue;
+use leo_core_ast::InputValue;
#[test]
fn test_assert() {
diff --git a/compiler/tests/statements/mod.rs b/compiler/tests/statements/mod.rs
index cb6efc3552..b3322ce785 100644
--- a/compiler/tests/statements/mod.rs
+++ b/compiler/tests/statements/mod.rs
@@ -15,7 +15,7 @@
// along with the Leo library. If not, see .
use crate::{assert_satisfied, expect_dynamic_check_error, generate_main_input, parse_program};
-use leo_typed::InputValue;
+use leo_core_ast::InputValue;
pub mod conditional;
diff --git a/typed/Cargo.toml b/core-ast/Cargo.toml
similarity index 86%
rename from typed/Cargo.toml
rename to core-ast/Cargo.toml
index 7836002d6f..9da4243a77 100644
--- a/typed/Cargo.toml
+++ b/core-ast/Cargo.toml
@@ -1,8 +1,8 @@
[package]
-name = "leo-typed"
+name = "leo-core-ast"
version = "1.0.3"
authors = [ "The Aleo Team " ]
-description = "Typed AST of the Leo programming language"
+description = "Core AST of the Leo programming language"
homepage = "https://aleo.org"
repository = "https://github.com/AleoHQ/leo"
keywords = [
@@ -18,12 +18,12 @@ license = "GPL-3.0"
edition = "2018"
[[bin]]
-name = "leo_typed_ast"
+name = "leo_core_ast"
path = "src/main.rs"
[[bench]]
-name = "typed_ast"
-path = "benches/typed_ast.rs"
+name = "core_ast"
+path = "benches/core_ast.rs"
harness = false
[dependencies.leo-ast]
diff --git a/typed/benches/big_circuit.leo b/core-ast/benches/big_circuit.leo
similarity index 100%
rename from typed/benches/big_circuit.leo
rename to core-ast/benches/big_circuit.leo
diff --git a/typed/benches/big_if_else.leo b/core-ast/benches/big_if_else.leo
similarity index 100%
rename from typed/benches/big_if_else.leo
rename to core-ast/benches/big_if_else.leo
diff --git a/typed/benches/big_ternary.leo b/core-ast/benches/big_ternary.leo
similarity index 100%
rename from typed/benches/big_ternary.leo
rename to core-ast/benches/big_ternary.leo
diff --git a/typed/benches/typed_ast.rs b/core-ast/benches/core_ast.rs
similarity index 99%
rename from typed/benches/typed_ast.rs
rename to core-ast/benches/core_ast.rs
index d7f473f14a..9b9d0cfb32 100644
--- a/typed/benches/typed_ast.rs
+++ b/core-ast/benches/core_ast.rs
@@ -15,7 +15,7 @@
// along with the Leo library. If not, see .
use leo_ast::LeoAst;
-use leo_typed::LeoCoreAst;
+use leo_core_ast::LeoCoreAst;
use criterion::{criterion_group, criterion_main, Criterion};
use std::{path::Path, time::Duration};
diff --git a/typed/benches/long_array.leo b/core-ast/benches/long_array.leo
similarity index 100%
rename from typed/benches/long_array.leo
rename to core-ast/benches/long_array.leo
diff --git a/typed/benches/long_expr.leo b/core-ast/benches/long_expr.leo
similarity index 100%
rename from typed/benches/long_expr.leo
rename to core-ast/benches/long_expr.leo
diff --git a/typed/benches/many_assigns.leo b/core-ast/benches/many_assigns.leo
similarity index 100%
rename from typed/benches/many_assigns.leo
rename to core-ast/benches/many_assigns.leo
diff --git a/typed/benches/many_foos.leo b/core-ast/benches/many_foos.leo
similarity index 100%
rename from typed/benches/many_foos.leo
rename to core-ast/benches/many_foos.leo
diff --git a/typed/src/annotation.rs b/core-ast/src/annotation.rs
similarity index 100%
rename from typed/src/annotation.rs
rename to core-ast/src/annotation.rs
diff --git a/typed/src/circuits/circuit.rs b/core-ast/src/circuits/circuit.rs
similarity index 100%
rename from typed/src/circuits/circuit.rs
rename to core-ast/src/circuits/circuit.rs
diff --git a/typed/src/circuits/circuit_member.rs b/core-ast/src/circuits/circuit_member.rs
similarity index 100%
rename from typed/src/circuits/circuit_member.rs
rename to core-ast/src/circuits/circuit_member.rs
diff --git a/typed/src/circuits/circuit_variable_definition.rs b/core-ast/src/circuits/circuit_variable_definition.rs
similarity index 100%
rename from typed/src/circuits/circuit_variable_definition.rs
rename to core-ast/src/circuits/circuit_variable_definition.rs
diff --git a/typed/src/circuits/mod.rs b/core-ast/src/circuits/mod.rs
similarity index 100%
rename from typed/src/circuits/mod.rs
rename to core-ast/src/circuits/mod.rs
diff --git a/typed/src/common/assignee.rs b/core-ast/src/common/assignee.rs
similarity index 100%
rename from typed/src/common/assignee.rs
rename to core-ast/src/common/assignee.rs
diff --git a/typed/src/common/declare.rs b/core-ast/src/common/declare.rs
similarity index 100%
rename from typed/src/common/declare.rs
rename to core-ast/src/common/declare.rs
diff --git a/typed/src/common/identifier.rs b/core-ast/src/common/identifier.rs
similarity index 100%
rename from typed/src/common/identifier.rs
rename to core-ast/src/common/identifier.rs
diff --git a/typed/src/common/mod.rs b/core-ast/src/common/mod.rs
similarity index 100%
rename from typed/src/common/mod.rs
rename to core-ast/src/common/mod.rs
diff --git a/typed/src/common/range_or_expression.rs b/core-ast/src/common/range_or_expression.rs
similarity index 100%
rename from typed/src/common/range_or_expression.rs
rename to core-ast/src/common/range_or_expression.rs
diff --git a/typed/src/common/span.rs b/core-ast/src/common/span.rs
similarity index 100%
rename from typed/src/common/span.rs
rename to core-ast/src/common/span.rs
diff --git a/typed/src/common/spread_or_expression.rs b/core-ast/src/common/spread_or_expression.rs
similarity index 100%
rename from typed/src/common/spread_or_expression.rs
rename to core-ast/src/common/spread_or_expression.rs
diff --git a/typed/src/common/variable_name.rs b/core-ast/src/common/variable_name.rs
similarity index 100%
rename from typed/src/common/variable_name.rs
rename to core-ast/src/common/variable_name.rs
diff --git a/typed/src/common/variables.rs b/core-ast/src/common/variables.rs
similarity index 100%
rename from typed/src/common/variables.rs
rename to core-ast/src/common/variables.rs
diff --git a/typed/src/console/console_function.rs b/core-ast/src/console/console_function.rs
similarity index 100%
rename from typed/src/console/console_function.rs
rename to core-ast/src/console/console_function.rs
diff --git a/typed/src/console/console_function_call.rs b/core-ast/src/console/console_function_call.rs
similarity index 100%
rename from typed/src/console/console_function_call.rs
rename to core-ast/src/console/console_function_call.rs
diff --git a/typed/src/console/formatted_container.rs b/core-ast/src/console/formatted_container.rs
similarity index 100%
rename from typed/src/console/formatted_container.rs
rename to core-ast/src/console/formatted_container.rs
diff --git a/typed/src/console/formatted_parameter.rs b/core-ast/src/console/formatted_parameter.rs
similarity index 100%
rename from typed/src/console/formatted_parameter.rs
rename to core-ast/src/console/formatted_parameter.rs
diff --git a/typed/src/console/formatted_string.rs b/core-ast/src/console/formatted_string.rs
similarity index 100%
rename from typed/src/console/formatted_string.rs
rename to core-ast/src/console/formatted_string.rs
diff --git a/typed/src/console/mod.rs b/core-ast/src/console/mod.rs
similarity index 100%
rename from typed/src/console/mod.rs
rename to core-ast/src/console/mod.rs
diff --git a/typed/src/errors/error.rs b/core-ast/src/errors/error.rs
similarity index 100%
rename from typed/src/errors/error.rs
rename to core-ast/src/errors/error.rs
diff --git a/typed/src/errors/mod.rs b/core-ast/src/errors/mod.rs
similarity index 100%
rename from typed/src/errors/mod.rs
rename to core-ast/src/errors/mod.rs
diff --git a/typed/src/expression.rs b/core-ast/src/expression.rs
similarity index 100%
rename from typed/src/expression.rs
rename to core-ast/src/expression.rs
diff --git a/typed/src/functions/function.rs b/core-ast/src/functions/function.rs
similarity index 100%
rename from typed/src/functions/function.rs
rename to core-ast/src/functions/function.rs
diff --git a/typed/src/functions/input/function_input.rs b/core-ast/src/functions/input/function_input.rs
similarity index 100%
rename from typed/src/functions/input/function_input.rs
rename to core-ast/src/functions/input/function_input.rs
diff --git a/typed/src/functions/input/input_variable.rs b/core-ast/src/functions/input/input_variable.rs
similarity index 100%
rename from typed/src/functions/input/input_variable.rs
rename to core-ast/src/functions/input/input_variable.rs
diff --git a/typed/src/functions/input/mod.rs b/core-ast/src/functions/input/mod.rs
similarity index 100%
rename from typed/src/functions/input/mod.rs
rename to core-ast/src/functions/input/mod.rs
diff --git a/typed/src/functions/mod.rs b/core-ast/src/functions/mod.rs
similarity index 100%
rename from typed/src/functions/mod.rs
rename to core-ast/src/functions/mod.rs
diff --git a/typed/src/functions/test_function.rs b/core-ast/src/functions/test_function.rs
similarity index 100%
rename from typed/src/functions/test_function.rs
rename to core-ast/src/functions/test_function.rs
diff --git a/typed/src/groups/group_coordinate.rs b/core-ast/src/groups/group_coordinate.rs
similarity index 100%
rename from typed/src/groups/group_coordinate.rs
rename to core-ast/src/groups/group_coordinate.rs
diff --git a/typed/src/groups/group_value.rs b/core-ast/src/groups/group_value.rs
similarity index 100%
rename from typed/src/groups/group_value.rs
rename to core-ast/src/groups/group_value.rs
diff --git a/typed/src/groups/mod.rs b/core-ast/src/groups/mod.rs
similarity index 100%
rename from typed/src/groups/mod.rs
rename to core-ast/src/groups/mod.rs
diff --git a/typed/src/imports/import.rs b/core-ast/src/imports/import.rs
similarity index 100%
rename from typed/src/imports/import.rs
rename to core-ast/src/imports/import.rs
diff --git a/typed/src/imports/import_symbol.rs b/core-ast/src/imports/import_symbol.rs
similarity index 100%
rename from typed/src/imports/import_symbol.rs
rename to core-ast/src/imports/import_symbol.rs
diff --git a/typed/src/imports/mod.rs b/core-ast/src/imports/mod.rs
similarity index 100%
rename from typed/src/imports/mod.rs
rename to core-ast/src/imports/mod.rs
diff --git a/typed/src/imports/package.rs b/core-ast/src/imports/package.rs
similarity index 100%
rename from typed/src/imports/package.rs
rename to core-ast/src/imports/package.rs
diff --git a/typed/src/imports/package_access.rs b/core-ast/src/imports/package_access.rs
similarity index 100%
rename from typed/src/imports/package_access.rs
rename to core-ast/src/imports/package_access.rs
diff --git a/typed/src/input/input.rs b/core-ast/src/input/input.rs
similarity index 100%
rename from typed/src/input/input.rs
rename to core-ast/src/input/input.rs
diff --git a/typed/src/input/input_value.rs b/core-ast/src/input/input_value.rs
similarity index 100%
rename from typed/src/input/input_value.rs
rename to core-ast/src/input/input_value.rs
diff --git a/typed/src/input/macros.rs b/core-ast/src/input/macros.rs
similarity index 100%
rename from typed/src/input/macros.rs
rename to core-ast/src/input/macros.rs
diff --git a/typed/src/input/mod.rs b/core-ast/src/input/mod.rs
similarity index 100%
rename from typed/src/input/mod.rs
rename to core-ast/src/input/mod.rs
diff --git a/typed/src/input/parameters/mod.rs b/core-ast/src/input/parameters/mod.rs
similarity index 100%
rename from typed/src/input/parameters/mod.rs
rename to core-ast/src/input/parameters/mod.rs
diff --git a/typed/src/input/parameters/parameter.rs b/core-ast/src/input/parameters/parameter.rs
similarity index 100%
rename from typed/src/input/parameters/parameter.rs
rename to core-ast/src/input/parameters/parameter.rs
diff --git a/typed/src/input/program_input/main_input.rs b/core-ast/src/input/program_input/main_input.rs
similarity index 100%
rename from typed/src/input/program_input/main_input.rs
rename to core-ast/src/input/program_input/main_input.rs
diff --git a/typed/src/input/program_input/mod.rs b/core-ast/src/input/program_input/mod.rs
similarity index 100%
rename from typed/src/input/program_input/mod.rs
rename to core-ast/src/input/program_input/mod.rs
diff --git a/typed/src/input/program_input/program_input.rs b/core-ast/src/input/program_input/program_input.rs
similarity index 100%
rename from typed/src/input/program_input/program_input.rs
rename to core-ast/src/input/program_input/program_input.rs
diff --git a/typed/src/input/program_input/registers.rs b/core-ast/src/input/program_input/registers.rs
similarity index 100%
rename from typed/src/input/program_input/registers.rs
rename to core-ast/src/input/program_input/registers.rs
diff --git a/typed/src/input/program_state/mod.rs b/core-ast/src/input/program_state/mod.rs
similarity index 100%
rename from typed/src/input/program_state/mod.rs
rename to core-ast/src/input/program_state/mod.rs
diff --git a/typed/src/input/program_state/private_state/mod.rs b/core-ast/src/input/program_state/private_state/mod.rs
similarity index 100%
rename from typed/src/input/program_state/private_state/mod.rs
rename to core-ast/src/input/program_state/private_state/mod.rs
diff --git a/typed/src/input/program_state/private_state/private_state.rs b/core-ast/src/input/program_state/private_state/private_state.rs
similarity index 100%
rename from typed/src/input/program_state/private_state/private_state.rs
rename to core-ast/src/input/program_state/private_state/private_state.rs
diff --git a/typed/src/input/program_state/private_state/record.rs b/core-ast/src/input/program_state/private_state/record.rs
similarity index 100%
rename from typed/src/input/program_state/private_state/record.rs
rename to core-ast/src/input/program_state/private_state/record.rs
diff --git a/typed/src/input/program_state/private_state/state_leaf.rs b/core-ast/src/input/program_state/private_state/state_leaf.rs
similarity index 100%
rename from typed/src/input/program_state/private_state/state_leaf.rs
rename to core-ast/src/input/program_state/private_state/state_leaf.rs
diff --git a/typed/src/input/program_state/program_state.rs b/core-ast/src/input/program_state/program_state.rs
similarity index 100%
rename from typed/src/input/program_state/program_state.rs
rename to core-ast/src/input/program_state/program_state.rs
diff --git a/typed/src/input/program_state/public_state/mod.rs b/core-ast/src/input/program_state/public_state/mod.rs
similarity index 100%
rename from typed/src/input/program_state/public_state/mod.rs
rename to core-ast/src/input/program_state/public_state/mod.rs
diff --git a/typed/src/input/program_state/public_state/public_state.rs b/core-ast/src/input/program_state/public_state/public_state.rs
similarity index 100%
rename from typed/src/input/program_state/public_state/public_state.rs
rename to core-ast/src/input/program_state/public_state/public_state.rs
diff --git a/typed/src/input/program_state/public_state/state.rs b/core-ast/src/input/program_state/public_state/state.rs
similarity index 100%
rename from typed/src/input/program_state/public_state/state.rs
rename to core-ast/src/input/program_state/public_state/state.rs
diff --git a/typed/src/lib.rs b/core-ast/src/lib.rs
similarity index 100%
rename from typed/src/lib.rs
rename to core-ast/src/lib.rs
diff --git a/typed/src/main.rs b/core-ast/src/main.rs
similarity index 92%
rename from typed/src/main.rs
rename to core-ast/src/main.rs
index 34005aa110..31d5c244b9 100644
--- a/typed/src/main.rs
+++ b/core-ast/src/main.rs
@@ -15,7 +15,7 @@
// along with the Leo library. If not, see .
use leo_ast::{LeoAst, ParserError};
-use leo_typed::LeoCoreAst;
+use leo_core_ast::LeoCoreAst;
use std::{env, fs, path::Path};
fn to_leo_core_tree(filepath: &Path) -> Result {
@@ -27,7 +27,7 @@ fn to_leo_core_tree(filepath: &Path) -> Result {
let ast = LeoAst::new(&program_filepath, &program_string)?;
// Parse the abstract core tree and constructs a typed core tree.
- let typed_ast = LeoCoreAst::new("leo_typed_tree", &ast);
+ let typed_ast = LeoCoreAst::new("leo_core_tree", &ast);
// Serializes the typed core tree into JSON format.
let serialized_typed_tree = LeoCoreAst::to_json_string(&typed_ast)?;
@@ -43,7 +43,7 @@ fn main() -> Result<(), ParserError> {
if cli_arguments.len() < 2 || cli_arguments.len() > 3 {
eprintln!("Warning - an invalid number of command-line arguments were provided.");
println!(
- "\nCommand-line usage:\n\n\tleo_typed_ast {{PATH/TO/INPUT_FILENAME}}.leo {{PATH/TO/OUTPUT_DIRECTORY (optional)}}\n"
+ "\nCommand-line usage:\n\n\tleo_core_ast {{PATH/TO/INPUT_FILENAME}}.leo {{PATH/TO/OUTPUT_DIRECTORY (optional)}}\n"
);
return Ok(()); // Exit innocently
}
diff --git a/typed/src/program.rs b/core-ast/src/program.rs
similarity index 100%
rename from typed/src/program.rs
rename to core-ast/src/program.rs
diff --git a/typed/src/statements/conditional_nested_or_end_statement.rs b/core-ast/src/statements/conditional_nested_or_end_statement.rs
similarity index 100%
rename from typed/src/statements/conditional_nested_or_end_statement.rs
rename to core-ast/src/statements/conditional_nested_or_end_statement.rs
diff --git a/typed/src/statements/conditional_statement.rs b/core-ast/src/statements/conditional_statement.rs
similarity index 100%
rename from typed/src/statements/conditional_statement.rs
rename to core-ast/src/statements/conditional_statement.rs
diff --git a/typed/src/statements/mod.rs b/core-ast/src/statements/mod.rs
similarity index 100%
rename from typed/src/statements/mod.rs
rename to core-ast/src/statements/mod.rs
diff --git a/typed/src/statements/statement.rs b/core-ast/src/statements/statement.rs
similarity index 100%
rename from typed/src/statements/statement.rs
rename to core-ast/src/statements/statement.rs
diff --git a/typed/src/types/integer_type.rs b/core-ast/src/types/integer_type.rs
similarity index 100%
rename from typed/src/types/integer_type.rs
rename to core-ast/src/types/integer_type.rs
diff --git a/typed/src/types/mod.rs b/core-ast/src/types/mod.rs
similarity index 100%
rename from typed/src/types/mod.rs
rename to core-ast/src/types/mod.rs
diff --git a/typed/src/types/type_.rs b/core-ast/src/types/type_.rs
similarity index 100%
rename from typed/src/types/type_.rs
rename to core-ast/src/types/type_.rs
diff --git a/typed/tests/mod.rs b/core-ast/tests/mod.rs
similarity index 100%
rename from typed/tests/mod.rs
rename to core-ast/tests/mod.rs
diff --git a/typed/tests/serialization/expected_typed_ast.json b/core-ast/tests/serialization/expected_typed_ast.json
similarity index 98%
rename from typed/tests/serialization/expected_typed_ast.json
rename to core-ast/tests/serialization/expected_typed_ast.json
index f12100d78d..8d3060e20f 100644
--- a/typed/tests/serialization/expected_typed_ast.json
+++ b/core-ast/tests/serialization/expected_typed_ast.json
@@ -1,5 +1,5 @@
{
- "name": "leo_typed_tree",
+ "name": "leo_core_tree",
"expected_input": [],
"imports": [],
"circuits": {},
diff --git a/typed/tests/serialization/json.rs b/core-ast/tests/serialization/json.rs
similarity index 97%
rename from typed/tests/serialization/json.rs
rename to core-ast/tests/serialization/json.rs
index ac83828675..6ee4c62a54 100644
--- a/typed/tests/serialization/json.rs
+++ b/core-ast/tests/serialization/json.rs
@@ -15,9 +15,9 @@
// along with the Leo library. If not, see .
use leo_ast::LeoAst;
-use leo_typed::LeoCoreAst;
+use leo_core_ast::LeoCoreAst;
#[cfg(not(feature = "ci_skip"))]
-use leo_typed::Program;
+use leo_core_ast::Program;
use std::path::{Path, PathBuf};
@@ -29,7 +29,7 @@ fn to_typed_ast(program_filepath: &Path) -> LeoCoreAst {
let ast = LeoAst::new(&program_filepath, &program_string).unwrap();
// Parse the abstract syntax tree and constructs a typed syntax tree.
- LeoCoreAst::new("leo_typed_tree", &ast)
+ LeoCoreAst::new("leo_core_tree", &ast)
}
#[test]
diff --git a/typed/tests/serialization/main.leo b/core-ast/tests/serialization/main.leo
similarity index 100%
rename from typed/tests/serialization/main.leo
rename to core-ast/tests/serialization/main.leo
diff --git a/typed/tests/serialization/mod.rs b/core-ast/tests/serialization/mod.rs
similarity index 100%
rename from typed/tests/serialization/mod.rs
rename to core-ast/tests/serialization/mod.rs
diff --git a/core/Cargo.toml b/core/Cargo.toml
index aa59743d09..98ba2197e5 100644
--- a/core/Cargo.toml
+++ b/core/Cargo.toml
@@ -21,8 +21,8 @@ edition = "2018"
path = "../gadgets"
version = "1.0.3"
-[dependencies.leo-typed]
-path = "../typed"
+[dependencies.leo-core-ast]
+path = "../core-ast"
version = "1.0.3"
[dependencies.snarkos-errors]
diff --git a/core/src/errors/core_circuit.rs b/core/src/errors/core_circuit.rs
index 408d9617df..5b2e81c70f 100644
--- a/core/src/errors/core_circuit.rs
+++ b/core/src/errors/core_circuit.rs
@@ -15,7 +15,7 @@
// along with the Leo library. If not, see .
use crate::Value;
-use leo_typed::{Error as FormattedError, Span};
+use leo_core_ast::{Error as FormattedError, Span};
use snarkos_errors::gadgets::SynthesisError;
diff --git a/core/src/errors/core_package.rs b/core/src/errors/core_package.rs
index 2a285abfb7..6c8726b906 100644
--- a/core/src/errors/core_package.rs
+++ b/core/src/errors/core_package.rs
@@ -13,7 +13,7 @@
// You should have received a copy of the GNU General Public License
// along with the Leo library. If not, see .
-use leo_typed::{Error as FormattedError, Span};
+use leo_core_ast::{Error as FormattedError, Span};
use std::path::Path;
diff --git a/core/src/errors/core_package_list.rs b/core/src/errors/core_package_list.rs
index cc23101924..57e4b292e7 100644
--- a/core/src/errors/core_package_list.rs
+++ b/core/src/errors/core_package_list.rs
@@ -14,7 +14,7 @@
// You should have received a copy of the GNU General Public License
// along with the Leo library. If not, see .
-use leo_typed::{Error as FormattedError, ImportSymbol, Span};
+use leo_core_ast::{Error as FormattedError, ImportSymbol, Span};
use crate::CorePackageError;
use std::path::Path;
diff --git a/core/src/errors/leo_core.rs b/core/src/errors/leo_core.rs
index 1c59ed9bc8..e5d42bf283 100644
--- a/core/src/errors/leo_core.rs
+++ b/core/src/errors/leo_core.rs
@@ -15,7 +15,7 @@
// along with the Leo library. If not, see .
use crate::{CoreCircuitError, CorePackageListError};
-use leo_typed::{Error as FormattedError, Span};
+use leo_core_ast::{Error as FormattedError, Span};
use std::path::Path;
diff --git a/core/src/lib.rs b/core/src/lib.rs
index 73317cc472..810ab32d47 100644
--- a/core/src/lib.rs
+++ b/core/src/lib.rs
@@ -27,7 +27,7 @@ pub mod types;
pub use self::types::*;
use crate::CoreCircuit;
-use leo_typed::Span;
+use leo_core_ast::Span;
use snarkos_models::{
curves::{Field, PrimeField},
gadgets::r1cs::ConstraintSystem,
diff --git a/core/src/packages/unstable/blake2s.rs b/core/src/packages/unstable/blake2s.rs
index a25c0e2739..f9ede1f7e2 100644
--- a/core/src/packages/unstable/blake2s.rs
+++ b/core/src/packages/unstable/blake2s.rs
@@ -16,7 +16,7 @@
use crate::{CoreCircuit, CoreCircuitError, Value};
-use leo_typed::{
+use leo_core_ast::{
Circuit,
CircuitMember,
Expression,
diff --git a/core/src/types/core_circuit.rs b/core/src/types/core_circuit.rs
index e1c3096e71..7d58d6b3c7 100644
--- a/core/src/types/core_circuit.rs
+++ b/core/src/types/core_circuit.rs
@@ -15,7 +15,7 @@
// along with the Leo library. If not, see .
use crate::{CoreCircuitError, Value};
-use leo_typed::{Circuit, Identifier, Span};
+use leo_core_ast::{Circuit, Identifier, Span};
use snarkos_models::{
curves::{Field, PrimeField},
diff --git a/core/src/types/core_circuit_struct_list.rs b/core/src/types/core_circuit_struct_list.rs
index 4a93867bf4..f8dd653ecc 100644
--- a/core/src/types/core_circuit_struct_list.rs
+++ b/core/src/types/core_circuit_struct_list.rs
@@ -14,7 +14,7 @@
// You should have received a copy of the GNU General Public License
// along with the Leo library. If not, see .
-use leo_typed::Circuit;
+use leo_core_ast::Circuit;
/// List of imported core circuit structs.
/// This struct is created from a `CorePackageList`
diff --git a/core/src/types/core_package.rs b/core/src/types/core_package.rs
index fa9a4e7a00..9435910765 100644
--- a/core/src/types/core_package.rs
+++ b/core/src/types/core_package.rs
@@ -20,7 +20,7 @@ use crate::{
CoreCircuitStructList,
CorePackageError,
};
-use leo_typed::{Identifier, ImportSymbol, Package, PackageAccess};
+use leo_core_ast::{Identifier, ImportSymbol, Package, PackageAccess};
use std::convert::TryFrom;
/// A core package dependency to be imported into a Leo program.
diff --git a/core/src/types/core_package_list.rs b/core/src/types/core_package_list.rs
index 142e9f9089..a70c8f886b 100644
--- a/core/src/types/core_package_list.rs
+++ b/core/src/types/core_package_list.rs
@@ -15,7 +15,7 @@
// along with the Leo library. If not, see .
use crate::{CoreCircuitStructList, CorePackage, CorePackageListError, UNSTABLE_CORE_PACKAGE_KEYWORD};
-use leo_typed::PackageAccess;
+use leo_core_ast::PackageAccess;
use std::convert::TryFrom;
/// A list of core package dependencies.
diff --git a/dynamic-check/Cargo.toml b/dynamic-check/Cargo.toml
index cd4bf2b8f4..37d1f1313c 100644
--- a/dynamic-check/Cargo.toml
+++ b/dynamic-check/Cargo.toml
@@ -32,8 +32,8 @@ version = "1.0"
path = "../symbol-table"
version = "1.0.3"
-[dependencies.leo-typed]
-path = "../typed"
+[dependencies.leo-core-ast]
+path = "../core-ast"
version = "1.0.3"
[dependencies.serde]
diff --git a/dynamic-check/src/assertions/type_assertion.rs b/dynamic-check/src/assertions/type_assertion.rs
index 030603cb22..fd01a4aaba 100644
--- a/dynamic-check/src/assertions/type_assertion.rs
+++ b/dynamic-check/src/assertions/type_assertion.rs
@@ -15,8 +15,8 @@
// along with the Leo library. If not, see .
use crate::{TypeAssertionError, TypeEquality, TypeMembership, TypeVariablePairs};
+use leo_core_ast::Span;
use leo_symbol_table::{Type, TypeVariable};
-use leo_typed::Span;
use serde::{Deserialize, Serialize};
diff --git a/dynamic-check/src/assertions/type_equality.rs b/dynamic-check/src/assertions/type_equality.rs
index d8380ee085..baeddd9ddd 100644
--- a/dynamic-check/src/assertions/type_equality.rs
+++ b/dynamic-check/src/assertions/type_equality.rs
@@ -15,8 +15,8 @@
// along with the Leo library. If not, see .
use crate::{TypeAssertionError, TypeVariablePairs};
+use leo_core_ast::Span;
use leo_symbol_table::{Type, TypeVariable};
-use leo_typed::Span;
use serde::{Deserialize, Serialize};
diff --git a/dynamic-check/src/assertions/type_membership.rs b/dynamic-check/src/assertions/type_membership.rs
index b1590a21f2..c31e22ce01 100644
--- a/dynamic-check/src/assertions/type_membership.rs
+++ b/dynamic-check/src/assertions/type_membership.rs
@@ -15,8 +15,8 @@
// along with the Leo library. If not, see .
use crate::TypeAssertionError;
+use leo_core_ast::Span;
use leo_symbol_table::{Type, TypeVariable};
-use leo_typed::Span;
use serde::{Deserialize, Serialize};
diff --git a/dynamic-check/src/assertions/type_variable_pair.rs b/dynamic-check/src/assertions/type_variable_pair.rs
index 446413f435..abde4984fe 100644
--- a/dynamic-check/src/assertions/type_variable_pair.rs
+++ b/dynamic-check/src/assertions/type_variable_pair.rs
@@ -15,8 +15,8 @@
// along with the Leo library. If not, see .
use crate::TypeAssertionError;
+use leo_core_ast::Span;
use leo_symbol_table::{flatten_array_type, Type, TypeVariable};
-use leo_typed::Span;
use std::borrow::Cow;
/// A type variable -> type pair.
diff --git a/dynamic-check/src/dynamic_check.rs b/dynamic-check/src/dynamic_check.rs
index 797084ce49..e5e31596b5 100644
--- a/dynamic-check/src/dynamic_check.rs
+++ b/dynamic-check/src/dynamic_check.rs
@@ -15,8 +15,8 @@
// along with the Leo library. If not, see .
use crate::{DynamicCheckError, Frame, Scope};
+use leo_core_ast::{Circuit, CircuitMember, Function, Program};
use leo_symbol_table::SymbolTable;
-use leo_typed::{Circuit, CircuitMember, Function, Program};
/// Performs a dynamic type inference check over a program.
pub struct DynamicCheck {
diff --git a/dynamic-check/src/errors/dynamic_check.rs b/dynamic-check/src/errors/dynamic_check.rs
index 8d0f29de94..a165a87a8d 100644
--- a/dynamic-check/src/errors/dynamic_check.rs
+++ b/dynamic-check/src/errors/dynamic_check.rs
@@ -15,7 +15,7 @@
// along with the Leo library. If not, see .
use crate::FrameError;
-use leo_typed::Error as FormattedError;
+use leo_core_ast::Error as FormattedError;
use std::path::Path;
diff --git a/dynamic-check/src/errors/frame.rs b/dynamic-check/src/errors/frame.rs
index 14e2914457..59c1bdeb96 100644
--- a/dynamic-check/src/errors/frame.rs
+++ b/dynamic-check/src/errors/frame.rs
@@ -15,8 +15,8 @@
// along with the Leo library. If not, see .
use crate::{ScopeError, TypeAssertionError};
+use leo_core_ast::{Error as FormattedError, Expression, Identifier, Span};
use leo_symbol_table::{Type, TypeError};
-use leo_typed::{Error as FormattedError, Expression, Identifier, Span};
use std::path::Path;
diff --git a/dynamic-check/src/errors/scope.rs b/dynamic-check/src/errors/scope.rs
index 125ad71c9f..1d834a8073 100644
--- a/dynamic-check/src/errors/scope.rs
+++ b/dynamic-check/src/errors/scope.rs
@@ -15,7 +15,7 @@
// along with the Leo library. If not, see .
use crate::VariableTableError;
-use leo_typed::Error as FormattedError;
+use leo_core_ast::Error as FormattedError;
use std::path::Path;
diff --git a/dynamic-check/src/errors/type_assertion.rs b/dynamic-check/src/errors/type_assertion.rs
index eca87557ab..0f55bd22d2 100644
--- a/dynamic-check/src/errors/type_assertion.rs
+++ b/dynamic-check/src/errors/type_assertion.rs
@@ -16,8 +16,8 @@
use crate::TypeMembership;
+use leo_core_ast::{Error as FormattedError, Span};
use leo_symbol_table::Type;
-use leo_typed::{Error as FormattedError, Span};
use std::path::Path;
diff --git a/dynamic-check/src/errors/variable_table.rs b/dynamic-check/src/errors/variable_table.rs
index d89432f0a0..cc359db3f9 100644
--- a/dynamic-check/src/errors/variable_table.rs
+++ b/dynamic-check/src/errors/variable_table.rs
@@ -14,7 +14,7 @@
// You should have received a copy of the GNU General Public License
// along with the Leo library. If not, see .
-use leo_typed::{Error as FormattedError, Span};
+use leo_core_ast::{Error as FormattedError, Span};
use std::path::Path;
diff --git a/dynamic-check/src/objects/frame.rs b/dynamic-check/src/objects/frame.rs
index 5ae47b1b44..ea2494f39a 100644
--- a/dynamic-check/src/objects/frame.rs
+++ b/dynamic-check/src/objects/frame.rs
@@ -15,8 +15,7 @@
// along with the Leo library. If not, see .
use crate::{FrameError, Scope, TypeAssertion};
-use leo_symbol_table::{Attribute, CircuitFunctionType, CircuitType, FunctionType, SymbolTable, Type, TypeVariable};
-use leo_typed::{
+use leo_core_ast::{
Assignee,
AssigneeAccess,
CircuitVariableDefinition,
@@ -33,6 +32,7 @@ use leo_typed::{
Statement,
Variables,
};
+use leo_symbol_table::{Attribute, CircuitFunctionType, CircuitType, FunctionType, SymbolTable, Type, TypeVariable};
/// A vector of `TypeAssertion` predicates created from a function body.
#[derive(Clone)]
diff --git a/dynamic-check/tests/mod.rs b/dynamic-check/tests/mod.rs
index dcb4638f0d..576be6d5e2 100644
--- a/dynamic-check/tests/mod.rs
+++ b/dynamic-check/tests/mod.rs
@@ -23,9 +23,9 @@ pub mod variables;
use leo_ast::LeoAst;
use leo_dynamic_check::DynamicCheck;
+use leo_core_ast::{Input, LeoCoreAst, Program};
use leo_imports::ImportParser;
use leo_symbol_table::SymbolTable;
-use leo_typed::{Input, LeoCoreAst, Program};
use std::path::PathBuf;
const TEST_PROGRAM_PATH: &str = "";
diff --git a/imports/Cargo.toml b/imports/Cargo.toml
index 6ef01f1426..a72bc81490 100644
--- a/imports/Cargo.toml
+++ b/imports/Cargo.toml
@@ -21,8 +21,8 @@ edition = "2018"
path = "../ast"
version = "1.0.3"
-[dependencies.leo-typed]
-path = "../typed"
+[dependencies.leo-core-ast]
+path = "../core-ast"
version = "1.0.3"
[dependencies.thiserror]
diff --git a/imports/src/errors/import_parser.rs b/imports/src/errors/import_parser.rs
index cb3ea1f4b1..3d745e135b 100644
--- a/imports/src/errors/import_parser.rs
+++ b/imports/src/errors/import_parser.rs
@@ -14,7 +14,7 @@
// You should have received a copy of the GNU General Public License
// along with the Leo library. If not, see .
use leo_ast::ParserError;
-use leo_typed::{Error as FormattedError, Identifier, Span};
+use leo_core_ast::{Error as FormattedError, Identifier, Span};
use std::{io, path::Path};
diff --git a/imports/src/parser/core_package.rs b/imports/src/parser/core_package.rs
index 3173257552..8227bbab7a 100644
--- a/imports/src/parser/core_package.rs
+++ b/imports/src/parser/core_package.rs
@@ -15,7 +15,7 @@
// along with the Leo library. If not, see .
use crate::{errors::ImportParserError, ImportParser};
-use leo_typed::Package;
+use leo_core_ast::Package;
pub static CORE_PACKAGE_NAME: &str = "core";
diff --git a/imports/src/parser/import_parser.rs b/imports/src/parser/import_parser.rs
index 35540c4d73..f5da49856b 100644
--- a/imports/src/parser/import_parser.rs
+++ b/imports/src/parser/import_parser.rs
@@ -15,7 +15,7 @@
// along with the Leo library. If not, see .
use crate::errors::ImportParserError;
-use leo_typed::{Package, Program};
+use leo_core_ast::{Package, Program};
use std::{
collections::{HashMap, HashSet},
diff --git a/imports/src/parser/parse_package.rs b/imports/src/parser/parse_package.rs
index 53749784e9..5656119d39 100644
--- a/imports/src/parser/parse_package.rs
+++ b/imports/src/parser/parse_package.rs
@@ -15,7 +15,7 @@
// along with the Leo library. If not, see .
use crate::{errors::ImportParserError, ImportParser, CORE_PACKAGE_NAME};
-use leo_typed::{Package, PackageAccess};
+use leo_core_ast::{Package, PackageAccess};
use std::{fs, fs::DirEntry, path::PathBuf};
diff --git a/imports/src/parser/parse_symbol.rs b/imports/src/parser/parse_symbol.rs
index 1b98912b27..f196b77cfe 100644
--- a/imports/src/parser/parse_symbol.rs
+++ b/imports/src/parser/parse_symbol.rs
@@ -16,7 +16,7 @@
use crate::{errors::ImportParserError, ImportParser};
use leo_ast::LeoAst;
-use leo_typed::{ImportSymbol, Program, Span};
+use leo_core_ast::{ImportSymbol, Program, Span};
use std::{ffi::OsString, fs::DirEntry, path::PathBuf};
diff --git a/state/Cargo.toml b/state/Cargo.toml
index be7db6f08d..36f172edd9 100644
--- a/state/Cargo.toml
+++ b/state/Cargo.toml
@@ -21,8 +21,8 @@ edition = "2018"
path = "../input"
version = "1.0.3"
-[dependencies.leo-typed]
-path = "../typed"
+[dependencies.leo-core-ast]
+path = "../core-ast"
version = "1.0.3"
[dependencies.snarkos-algorithms]
diff --git a/state/src/local_data_commitment/local_data_commitment.rs b/state/src/local_data_commitment/local_data_commitment.rs
index 6a8f2906b3..0b3d33ee9a 100644
--- a/state/src/local_data_commitment/local_data_commitment.rs
+++ b/state/src/local_data_commitment/local_data_commitment.rs
@@ -15,7 +15,7 @@
// along with the Leo library. If not, see .
use crate::{verify_record_commitment, LocalDataVerificationError, StateLeafValues, StateValues};
-use leo_typed::Input as TypedInput;
+use leo_core_ast::Input as TypedInput;
use snarkos_algorithms::commitment_tree::CommitmentMerklePath;
use snarkos_dpc::base_dpc::{
diff --git a/state/src/local_data_commitment/state_leaf_values.rs b/state/src/local_data_commitment/state_leaf_values.rs
index f7ca617ba4..4f01fad3fd 100644
--- a/state/src/local_data_commitment/state_leaf_values.rs
+++ b/state/src/local_data_commitment/state_leaf_values.rs
@@ -15,7 +15,7 @@
// along with the Leo library. If not, see .
use crate::{find_input, input_to_integer_string, input_to_u8_vec, StateLeafValuesError};
-use leo_typed::StateLeaf as TypedStateLeaf;
+use leo_core_ast::StateLeaf as TypedStateLeaf;
use std::convert::TryFrom;
diff --git a/state/src/local_data_commitment/state_values.rs b/state/src/local_data_commitment/state_values.rs
index 7fbba3dd6e..7dcdc9c783 100644
--- a/state/src/local_data_commitment/state_values.rs
+++ b/state/src/local_data_commitment/state_values.rs
@@ -15,7 +15,7 @@
// along with the Leo library. If not, see .
use crate::{find_input, input_to_integer_string, input_to_u8_vec, StateValuesError};
-use leo_typed::State as TypedState;
+use leo_core_ast::State as TypedState;
use std::convert::TryFrom;
diff --git a/state/src/record_commitment/dpc_record_values.rs b/state/src/record_commitment/dpc_record_values.rs
index 4137267d40..1b61660f60 100644
--- a/state/src/record_commitment/dpc_record_values.rs
+++ b/state/src/record_commitment/dpc_record_values.rs
@@ -15,7 +15,7 @@
// along with the Leo library. If not, see .
use crate::{utilities::*, DPCRecordValuesError};
-use leo_typed::Record as TypedRecord;
+use leo_core_ast::Record as TypedRecord;
use snarkos_dpc::base_dpc::instantiated::Components;
use snarkos_objects::AccountAddress;
diff --git a/state/src/record_commitment/record_commitment.rs b/state/src/record_commitment/record_commitment.rs
index 1908c5a3da..c42cac2d48 100644
--- a/state/src/record_commitment/record_commitment.rs
+++ b/state/src/record_commitment/record_commitment.rs
@@ -15,7 +15,7 @@
// along with the Leo library. If not, see .
use crate::{DPCRecordValues, RecordVerificationError};
-use leo_typed::Record as TypedRecord;
+use leo_core_ast::Record as TypedRecord;
use snarkos_dpc::base_dpc::{
instantiated::{Components, RecordCommitment},
diff --git a/state/src/utilities/input_value.rs b/state/src/utilities/input_value.rs
index 9e1cc9421b..2500acde9b 100644
--- a/state/src/utilities/input_value.rs
+++ b/state/src/utilities/input_value.rs
@@ -15,7 +15,7 @@
// along with the Leo library. If not, see .
use crate::InputValueError;
-use leo_typed::{InputValue, Parameter};
+use leo_core_ast::{InputValue, Parameter};
use std::collections::HashMap;
diff --git a/state/tests/test_verify_local_data_commitment.rs b/state/tests/test_verify_local_data_commitment.rs
index 89b8db06a3..226fbbfb71 100644
--- a/state/tests/test_verify_local_data_commitment.rs
+++ b/state/tests/test_verify_local_data_commitment.rs
@@ -14,9 +14,9 @@
// You should have received a copy of the GNU General Public License
// along with the Leo library. If not, see .
+use leo_core_ast::Input;
use leo_input::LeoInputParser;
use leo_state::verify_local_data_commitment;
-use leo_typed::Input;
use snarkos_dpc::base_dpc::{instantiated::*, record_payload::RecordPayload, DPC};
use snarkos_models::{
diff --git a/state/tests/test_verify_record_commitment.rs b/state/tests/test_verify_record_commitment.rs
index 63dda73cb1..be03b32094 100644
--- a/state/tests/test_verify_record_commitment.rs
+++ b/state/tests/test_verify_record_commitment.rs
@@ -14,9 +14,9 @@
// You should have received a copy of the GNU General Public License
// along with the Leo library. If not, see .
+use leo_core_ast::Input;
use leo_input::LeoInputParser;
use leo_state::verify_record_commitment;
-use leo_typed::Input;
use snarkos_dpc::base_dpc::instantiated::*;
diff --git a/symbol-table/Cargo.toml b/symbol-table/Cargo.toml
index 8527bf14e8..53f94a769e 100644
--- a/symbol-table/Cargo.toml
+++ b/symbol-table/Cargo.toml
@@ -29,8 +29,8 @@ version = "1.0.3"
path = "../imports"
version = "1.0.3"
-[dependencies.leo-typed]
-path = "../typed"
+[dependencies.leo-core-ast]
+path = "../core-ast"
version = "1.0.3"
[dependencies.serde]
diff --git a/symbol-table/src/errors/symbol_table.rs b/symbol-table/src/errors/symbol_table.rs
index 57efaec0b8..839d3b357f 100644
--- a/symbol-table/src/errors/symbol_table.rs
+++ b/symbol-table/src/errors/symbol_table.rs
@@ -16,7 +16,7 @@
use crate::{TypeError, UserDefinedType};
use leo_core::{CorePackageListError, LeoCoreError};
-use leo_typed::{Error as FormattedError, ImportSymbol, Program, Span};
+use leo_core_ast::{Error as FormattedError, ImportSymbol, Program, Span};
use std::path::Path;
diff --git a/symbol-table/src/errors/type_.rs b/symbol-table/src/errors/type_.rs
index 5bdaff6cf0..487b323b4a 100644
--- a/symbol-table/src/errors/type_.rs
+++ b/symbol-table/src/errors/type_.rs
@@ -15,7 +15,7 @@
// along with the Leo library. If not, see .
use crate::Type;
-use leo_typed::{Error as FormattedError, Identifier, Span};
+use leo_core_ast::{Error as FormattedError, Identifier, Span};
use std::path::Path;
diff --git a/symbol-table/src/imports/imported_symbols.rs b/symbol-table/src/imports/imported_symbols.rs
index f42542471a..a68d6f5f31 100644
--- a/symbol-table/src/imports/imported_symbols.rs
+++ b/symbol-table/src/imports/imported_symbols.rs
@@ -14,7 +14,7 @@
// You should have received a copy of the GNU General Public License
// along with the Leo library. If not, see .
-use leo_typed::{ImportStatement, ImportSymbol, Package, PackageAccess};
+use leo_core_ast::{ImportStatement, ImportSymbol, Package, PackageAccess};
/// Stores the the package file name and imported symbol from an import statement
#[derive(Debug)]
diff --git a/symbol-table/src/symbol_table.rs b/symbol-table/src/symbol_table.rs
index eb6bf1a8da..2e2a8e0409 100644
--- a/symbol-table/src/symbol_table.rs
+++ b/symbol-table/src/symbol_table.rs
@@ -16,8 +16,8 @@
use crate::{CircuitType, CircuitVariableType, FunctionType, ImportedSymbols, SymbolTableError, UserDefinedType};
use leo_core::CorePackageList;
+use leo_core_ast::{Circuit, Function, Identifier, ImportStatement, ImportSymbol, Input, Package, Program};
use leo_imports::ImportParser;
-use leo_typed::{Circuit, Function, Identifier, ImportStatement, ImportSymbol, Input, Package, Program};
use std::collections::{HashMap, HashSet};
diff --git a/symbol-table/src/types/circuits/circuit.rs b/symbol-table/src/types/circuits/circuit.rs
index 270d0a9805..5a1b6e0f4b 100644
--- a/symbol-table/src/types/circuits/circuit.rs
+++ b/symbol-table/src/types/circuits/circuit.rs
@@ -22,7 +22,7 @@ use crate::{
Type,
TypeError,
};
-use leo_typed::{Circuit, CircuitMember, Identifier, InputValue, Parameter, Span};
+use leo_core_ast::{Circuit, CircuitMember, Identifier, InputValue, Parameter, Span};
use serde::{Deserialize, Serialize};
use std::{
diff --git a/symbol-table/src/types/circuits/circuit_variable.rs b/symbol-table/src/types/circuits/circuit_variable.rs
index 275687203d..dfc19e7336 100644
--- a/symbol-table/src/types/circuits/circuit_variable.rs
+++ b/symbol-table/src/types/circuits/circuit_variable.rs
@@ -15,7 +15,7 @@
// along with the Leo library. If not, see .
use crate::{Attribute, CircuitType, Type};
-use leo_typed::Identifier;
+use leo_core_ast::Identifier;
use serde::{Deserialize, Serialize};
diff --git a/symbol-table/src/types/functions/function.rs b/symbol-table/src/types/functions/function.rs
index 9531b45a90..2cddcdef4b 100644
--- a/symbol-table/src/types/functions/function.rs
+++ b/symbol-table/src/types/functions/function.rs
@@ -19,7 +19,7 @@ use crate::{
SymbolTable,
TypeError,
};
-use leo_typed::{Function, Identifier};
+use leo_core_ast::{Function, Identifier};
use serde::{Deserialize, Serialize};
use std::hash::{Hash, Hasher};
diff --git a/symbol-table/src/types/functions/function_input.rs b/symbol-table/src/types/functions/function_input.rs
index 40a45024fd..7d04ecd643 100644
--- a/symbol-table/src/types/functions/function_input.rs
+++ b/symbol-table/src/types/functions/function_input.rs
@@ -15,7 +15,7 @@
// along with the Leo library. If not, see .
use crate::{FunctionInputVariableType, SymbolTable, Type, TypeError};
-use leo_typed::{FunctionInput, Identifier};
+use leo_core_ast::{FunctionInput, Identifier};
use serde::{Deserialize, Serialize};
diff --git a/symbol-table/src/types/functions/function_input_variable.rs b/symbol-table/src/types/functions/function_input_variable.rs
index 1dde943094..53069b43a1 100644
--- a/symbol-table/src/types/functions/function_input_variable.rs
+++ b/symbol-table/src/types/functions/function_input_variable.rs
@@ -15,7 +15,7 @@
// along with the Leo library. If not, see .
use crate::{Attribute, SymbolTable, Type, TypeError, UserDefinedType};
-use leo_typed::{FunctionInputVariable, Identifier, Span};
+use leo_core_ast::{FunctionInputVariable, Identifier, Span};
use serde::{Deserialize, Serialize};
use std::hash::{Hash, Hasher};
diff --git a/symbol-table/src/types/functions/function_output.rs b/symbol-table/src/types/functions/function_output.rs
index c0bae87201..dcefe2b207 100644
--- a/symbol-table/src/types/functions/function_output.rs
+++ b/symbol-table/src/types/functions/function_output.rs
@@ -16,7 +16,7 @@
use crate::{SymbolTable, Type, TypeError};
-use leo_typed::{Identifier, Span, Type as UnresolvedType};
+use leo_core_ast::{Identifier, Span, Type as UnresolvedType};
use serde::{Deserialize, Serialize};
diff --git a/symbol-table/src/types/type_.rs b/symbol-table/src/types/type_.rs
index c3f55b55a4..110a2607bc 100644
--- a/symbol-table/src/types/type_.rs
+++ b/symbol-table/src/types/type_.rs
@@ -14,7 +14,7 @@
// You should have received a copy of the GNU General Public License
// along with the Leo library. If not, see .
use crate::{SymbolTable, TypeError, TypeVariable};
-use leo_typed::{Identifier, IntegerType, Span, Type as UnresolvedType};
+use leo_core_ast::{Identifier, IntegerType, Span, Type as UnresolvedType};
use serde::{Deserialize, Serialize};
use std::{
diff --git a/symbol-table/src/types/type_variable.rs b/symbol-table/src/types/type_variable.rs
index 7e19139324..f9e5420433 100644
--- a/symbol-table/src/types/type_variable.rs
+++ b/symbol-table/src/types/type_variable.rs
@@ -13,7 +13,7 @@
// You should have received a copy of the GNU General Public License
// along with the Leo library. If not, see .
-use leo_typed::Identifier;
+use leo_core_ast::Identifier;
use serde::{Deserialize, Serialize};
use std::fmt;
diff --git a/symbol-table/src/types/user_defined/user_defined_type.rs b/symbol-table/src/types/user_defined/user_defined_type.rs
index 7aae9530fb..3a536f0d08 100644
--- a/symbol-table/src/types/user_defined/user_defined_type.rs
+++ b/symbol-table/src/types/user_defined/user_defined_type.rs
@@ -14,7 +14,7 @@
// You should have received a copy of the GNU General Public License
// along with the Leo library. If not, see .
use crate::{Attribute, FunctionInputVariableType, Type};
-use leo_typed::{Circuit, Function, Identifier};
+use leo_core_ast::{Circuit, Function, Identifier};
use std::{
fmt,
diff --git a/symbol-table/tests/mod.rs b/symbol-table/tests/mod.rs
index a9aea958a7..f262716685 100644
--- a/symbol-table/tests/mod.rs
+++ b/symbol-table/tests/mod.rs
@@ -17,8 +17,8 @@
pub mod symbol_table;
use leo_ast::LeoAst;
+use leo_core_ast::{Input, LeoCoreAst};
use leo_symbol_table::{SymbolTable, SymbolTableError};
-use leo_typed::{Input, LeoCoreAst};
use leo_imports::ImportParser;
use std::path::PathBuf;