Skip to content

Commit

Permalink
chore: update crate versions to v0.3
Browse files Browse the repository at this point in the history
  • Loading branch information
bobbinth committed Jul 12, 2023
1 parent f942506 commit 5f7411b
Show file tree
Hide file tree
Showing 11 changed files with 75 additions and 56 deletions.
32 changes: 16 additions & 16 deletions air-script/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,34 +1,34 @@
[package]
name = "air-script"
version = "0.2.0"
description="AirScript language compiler"
version = "0.3.0"
description = "AirScript language compiler"
authors = ["miden contributors"]
readme="README.md"
readme = "README.md"
license = "MIT"
repository = "https://github.com/0xPolygonMiden/air-script"
documentation = "https://0xpolygonmiden.github.io/air-script/"
categories = ["compilers", "cryptography"]
keywords = ["air", "stark", "zero-knowledge", "zkp"]
edition = "2021"
rust-version = "1.65"
rust-version = "1.67"

[[bin]]
name = "airc"
path = "src/main.rs"

[dependencies]
air-ir = { path = "../ir", version = "0.2.0" }
air-parser = { path = "../parser", version = "0.2.0" }
air-pass = { path = "../pass", version = "0.1.0" }
air-codegen-winter = { path = "../codegen/winterfell", version = "0.2.0" }
air-codegen-masm = { path = "../codegen/masm" }
env_logger = "0.10.0"
air-ir = { package = "air-ir", path = "../ir", version = "0.3" }
air-parser = { package = "air-parser", path = "../parser", version = "0.3" }
air-pass = { package = "air-pass", path = "../pass", version = "0.1" }
air-codegen-masm = { package = "air-codegen-masm", path = "../codegen/masm", version = "0.1" }
air-codegen-winter = { package = "air-codegen-winter", path = "../codegen/winterfell", version = "0.3" }
clap = {version = "4.2", features = ["derive"] }
env_logger = "0.10"
log = { version = "0.4", default-features = false }
miden-diagnostics = { git = "https://github.com/0xPolygonMiden/miden-diagnostics" }
clap = {version = "4.2", features = ["derive"]}
miden-diagnostics = "0.1"

[dev-dependencies]
winter-air = { package = "winter-air", version = "0.5.1", default-features = false }
winter-math = { package = "winter-math", version = "0.5.1", default-features = false }
winter-utils = { package = "winter-utils", version = "0.5.1", default-features = false }
expect-test = "1.4.0"
expect-test = "1.4"
winter-air = { package = "winter-air", version = "0.6", default-features = false }
winter-math = { package = "winter-math", version = "0.6", default-features = false }
winter-utils = { package = "winter-utils", version = "0.6", default-features = false }
23 changes: 16 additions & 7 deletions codegen/masm/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,18 +1,27 @@
[package]
name = "air-codegen-masm"
version = "0.1.0"
description = "Miden Assembly code generator for the AirScript language"
authors = ["miden contributors"]
readme = "README.md"
license = "MIT"
repository = "https://github.com/0xPolygonMiden/air-script"
categories = ["compilers", "cryptography"]
keywords = ["air", "stark", "winterfell", "zero-knowledge", "zkp"]
edition = "2021"
rust-version = "1.67"

[dependencies]
air-ir = { path = "../../ir", version = "0.2.0" }
air-ir = { package = "air-ir", path = "../../ir", version = "0.3" }
anyhow = "1.0"
winter-prover = { version = "0.6", default-features = false }
miden-processor = { git = "https://github.com/0xPolygonMiden/miden-vm", features = ["internals"], default-features = false }
miden-core = { package = "miden-core", version = "0.6", default-features = false }
thiserror = "1.0"
winter-math = { package = "winter-math", version = "0.6", default-features = false }

[dev-dependencies]
air-parser = { path = "../../parser", version = "0.2.0" }
air-parser = { path = "../../parser" }
air-pass = { path = "../../pass" }
miden = "0.3.0"
miden-diagnostics = { git = "https://github.com/0xpolygonmiden/miden-diagnostics" }
miden-assembly = { git = "https://github.com/0xPolygonMiden/miden-vm", default-features = false }
miden-assembly = { package = "miden-assembly", version = "0.6", default-features = false }
miden-processor = { package = "miden-processor", version = "0.6", features = ["internals"], default-features = false }
miden-diagnostics = "0.1"
winter-air = { package = "winter-air", version = "0.6", default-features = false }
4 changes: 2 additions & 2 deletions codegen/masm/src/codegen.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,10 @@ use air_ir::{
Air, ConstraintDomain, ConstraintRoot, Identifier, NodeIndex, Operation, PeriodicColumn,
TraceSegmentId, Value,
};
use miden_processor::math::{Felt, StarkField};
use miden_core::{Felt, StarkField};
use std::collections::btree_map::BTreeMap;
use std::mem::{replace, take};
use winter_prover::math::fft;
use winter_math::fft;

#[derive(Default)]
pub struct CodeGenerator {
Expand Down
2 changes: 1 addition & 1 deletion codegen/masm/src/writer.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
use miden_processor::math::{Felt, StarkField};
use miden_core::{Felt, StarkField};
use std::borrow::{Borrow, Cow};

#[derive(Debug, Clone, Copy)]
Expand Down
2 changes: 1 addition & 1 deletion codegen/masm/tests/test_divisor.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ use miden_processor::{
math::{Felt, FieldElement},
AdviceInputs, Kernel, MemAdviceProvider, Process, QuadExtension, StackInputs,
};
use winter_prover::{Assertion, ConstraintDivisor};
use winter_air::{Assertion, ConstraintDivisor};

mod utils;
use utils::{codegen, test_code, to_stack_order, Data};
Expand Down
12 changes: 6 additions & 6 deletions codegen/winterfell/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
[package]
name = "air-codegen-winter"
version = "0.2.0"
description="Winterfell code generator for the AirScript language"
version = "0.3.0"
description = "Winterfell code generator for the AirScript language"
authors = ["miden contributors"]
readme="README.md"
readme = "README.md"
license = "MIT"
repository = "https://github.com/0xPolygonMiden/air-script"
categories = ["compilers", "cryptography"]
keywords = ["air", "stark", "winterfell", "zero-knowledge", "zkp"]
edition = "2021"
rust-version = "1.65"
rust-version = "1.67"

[dependencies]
air-ir = { path="../../ir", version="0.2.0" }
air-ir = { package = "air-ir", path = "../../ir", version = "0.3" }
anyhow = "1.0"
codegen = "0.2.0"
codegen = "0.2"
14 changes: 7 additions & 7 deletions ir/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,19 +1,19 @@
[package]
name = "air-ir"
version = "0.2.0"
description="Intermediate representation for the AirScript language"
version = "0.3.0"
description = "Intermediate representation for the AirScript language"
authors = ["miden contributors"]
readme="README.md"
readme = "README.md"
license = "MIT"
repository = "https://github.com/0xPolygonMiden/air-script"
categories = ["compilers", "cryptography"]
keywords = ["air", "stark", "zero-knowledge", "zkp"]
edition = "2021"
rust-version = "1.65"
rust-version = "1.67"

[dependencies]
air-parser = { path = "../parser", version = "0.2.0" }
air-pass = { path = "../pass", version = "0.1.0" }
air-parser = { package = "air-parser", path = "../parser", version = "0.3" }
air-pass = { package = "air-pass", path = "../pass", version = "0.1" }
anyhow = "1.0"
miden-diagnostics = { git = "https://github.com/0xpolygonmiden/miden-diagnostics" }
miden-diagnostics = "0.1"
thiserror = "1.0"
12 changes: 9 additions & 3 deletions ir/src/passes/translate.rs
Original file line number Diff line number Diff line change
Expand Up @@ -293,9 +293,13 @@ impl<'a> AirBuilder<'a> {
// The left-hand side of a boundary constraint equality expression is always a bounded symbol access
// against a trace column. It is fine to panic here if that is ever violated.
let ast::ScalarExpr::BoundedSymbolAccess(ref access) = lhs else {
self.diagnostics.diagnostic(Severity::Bug)
self.diagnostics
.diagnostic(Severity::Bug)
.with_message("invalid boundary constraint")
.with_primary_label(lhs_span, "expected bounded trace column access here, e.g. 'main[0].first'")
.with_primary_label(
lhs_span,
"expected bounded trace column access here, e.g. 'main[0].first'",
)
.emit();
return Err(CompileError::Failed);
};
Expand Down Expand Up @@ -415,7 +419,9 @@ impl<'a> AirBuilder<'a> {
fn insert_binary_expr(&mut self, expr: &ast::BinaryExpr) -> NodeIndex {
if expr.op == ast::BinaryOp::Exp {
let lhs = self.insert_scalar_expr(expr.lhs.as_ref());
let ast::ScalarExpr::Const(rhs) = expr.rhs.as_ref() else { unreachable!(); };
let ast::ScalarExpr::Const(rhs) = expr.rhs.as_ref() else {
unreachable!();
};
return self.insert_op(Operation::Exp(lhs, rhs.item as usize));
}

Expand Down
18 changes: 9 additions & 9 deletions parser/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,24 +1,24 @@
[package]
name = "air-parser"
version = "0.2.0"
description="Parser for the AirScript language"
version = "0.3.0"
description = "Parser for the AirScript language"
authors = ["miden contributors"]
readme="README.md"
readme = "README.md"
license = "MIT"
repository = "https://github.com/0xPolygonMiden/air-script"
categories = ["compilers", "cryptography", "parser-implementations"]
keywords = ["air", "stark", "zero-knowledge", "zkp"]
edition = "2021"
rust-version = "1.65"
rust-version = "1.67"

[build-dependencies]
lalrpop = { version = "0.20.0", default-features = false }
lalrpop = { version = "0.20", default-features = false }

[dependencies]
air-pass = { path = "../pass", version = "0.1.0" }
miden-diagnostics = { git = "https://github.com/0xPolygonMiden/miden-diagnostics" }
miden-parsing = { git = "https://github.com/0xPolygonMiden/miden-parsing" }
lalrpop-util = { version = "0.20.0" }
air-pass = { package = "air-pass", path = "../pass", version = "0.1" }
miden-diagnostics = "0.1"
miden-parsing = "0.1"
lalrpop-util="0.20"
lazy_static = "1.4"
petgraph = "0.6"
regex = "1"
Expand Down
8 changes: 6 additions & 2 deletions parser/src/transforms/inlining.rs
Original file line number Diff line number Diff line change
Expand Up @@ -638,7 +638,9 @@ impl<'a> Inlining<'a> {
let mut statements = vec![];

// Get the number of iterations in this comprehension
let Type::Vector(num_iterations) = expr.ty.unwrap() else { panic!("invalid comprehension type"); };
let Type::Vector(num_iterations) = expr.ty.unwrap() else {
panic!("invalid comprehension type");
};

// Step the iterables for each iteration, giving each it's own lexical scope
for i in 0..num_iterations {
Expand Down Expand Up @@ -1068,7 +1070,9 @@ impl<'a> Inlining<'a> {
// The input expression must have been a symbol access, as matrices of columns
// aren't a thing, and there is no other expression type which can produce trace
// bindings.
let Expr::SymbolAccess(ref access) = input else { panic!("unexpected element in trace column vector: {:#?}", input) };
let Expr::SymbolAccess(ref access) = input else {
panic!("unexpected element in trace column vector: {:#?}", input)
};
// Unless we have leftover input, initialize `binding_ty` with the binding type of this input
let bt = binding_ty
.take()
Expand Down
4 changes: 2 additions & 2 deletions pass/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
[package]
name = "air-pass"
version = "0.1.0"
description="Provides reusable compiler pass infrastructure for the AirScript compiler"
description = "Reusable compiler pass infrastructure for the AirScript compiler"
authors = ["Paul Schoenfelder"]
license = "MIT"
repository = "https://github.com/0xPolygonMiden/air-script"
categories = ["compilers"]
edition = "2021"
rust-version = "1.65"
rust-version = "1.67"

[dependencies]

0 comments on commit 5f7411b

Please sign in to comment.