From 9e153b9ebd68c809a8c7aabf1fa676b3fe4af7ca Mon Sep 17 00:00:00 2001 From: Sergio Chouhy Date: Thu, 17 Jul 2025 10:10:39 -0300 Subject: [PATCH] rename crates --- risc0-selective-privacy-poc/Cargo.toml | 2 +- risc0-selective-privacy-poc/core/Cargo.toml | 5 +++-- .../examples/private_execution.rs | 2 +- .../examples/public_execution.rs | 2 +- .../outer_methods/guest/Cargo.toml | 4 ++-- .../outer_methods/guest/src/bin/outer.rs | 2 +- risc0-selective-privacy-poc/src/lib.rs | 10 +++++----- .../transfer_methods/guest/Cargo.toml | 4 ++-- .../transfer_methods/guest/src/bin/transfer.rs | 9 ++++++--- 9 files changed, 22 insertions(+), 18 deletions(-) diff --git a/risc0-selective-privacy-poc/Cargo.toml b/risc0-selective-privacy-poc/Cargo.toml index a90a0e3..e159416 100644 --- a/risc0-selective-privacy-poc/Cargo.toml +++ b/risc0-selective-privacy-poc/Cargo.toml @@ -5,7 +5,7 @@ edition = "2021" [dependencies] risc0-zkvm = "2.2" -toy-example-core = { path = "core" } +core = { path = "core" } transfer-methods = { path = "transfer_methods" } outer-methods = { path = "outer_methods" } serde = "1.0" diff --git a/risc0-selective-privacy-poc/core/Cargo.toml b/risc0-selective-privacy-poc/core/Cargo.toml index 1d84937..4e57901 100644 --- a/risc0-selective-privacy-poc/core/Cargo.toml +++ b/risc0-selective-privacy-poc/core/Cargo.toml @@ -1,8 +1,9 @@ [package] -name = "toy-example-core" +name = "core" version = "0.12.0" edition = "2021" [dependencies] risc0-zkvm = "2.0.2" -serde = { version = "1.0", default-features = false } \ No newline at end of file +serde = { version = "1.0", default-features = false } + diff --git a/risc0-selective-privacy-poc/examples/private_execution.rs b/risc0-selective-privacy-poc/examples/private_execution.rs index 86dd25f..501bcff 100644 --- a/risc0-selective-privacy-poc/examples/private_execution.rs +++ b/risc0-selective-privacy-poc/examples/private_execution.rs @@ -1,7 +1,7 @@ use nssa::program::TransferProgram; use outer_methods::OUTER_ID; use sparse_merkle_tree::SparseMerkleTree; -use toy_example_core::{ +use core::{ account::Account, bytes_to_words, input::InputVisibiility, diff --git a/risc0-selective-privacy-poc/examples/public_execution.rs b/risc0-selective-privacy-poc/examples/public_execution.rs index 7deb9a2..1095886 100644 --- a/risc0-selective-privacy-poc/examples/public_execution.rs +++ b/risc0-selective-privacy-poc/examples/public_execution.rs @@ -1,5 +1,5 @@ use risc0_zkvm::{default_executor, ExecutorEnv}; -use toy_example_core::account::Account; +use core::account::Account; use transfer_methods::TRANSFER_ELF; use nssa; diff --git a/risc0-selective-privacy-poc/outer_methods/guest/Cargo.toml b/risc0-selective-privacy-poc/outer_methods/guest/Cargo.toml index ceb31ad..4585a49 100644 --- a/risc0-selective-privacy-poc/outer_methods/guest/Cargo.toml +++ b/risc0-selective-privacy-poc/outer_methods/guest/Cargo.toml @@ -1,5 +1,5 @@ [package] -name = "toy_example" +name = "outer" version = "0.1.0" edition = "2021" @@ -7,5 +7,5 @@ edition = "2021" [dependencies] risc0-zkvm = { version = "2.2.0", default-features = false, features = ['std'] } -toy-example-core = {path = "../../core" } +core = {path = "../../core" } transfer-methods = {path = "../../transfer_methods"} diff --git a/risc0-selective-privacy-poc/outer_methods/guest/src/bin/outer.rs b/risc0-selective-privacy-poc/outer_methods/guest/src/bin/outer.rs index 62b4b33..0f67546 100644 --- a/risc0-selective-privacy-poc/outer_methods/guest/src/bin/outer.rs +++ b/risc0-selective-privacy-poc/outer_methods/guest/src/bin/outer.rs @@ -1,5 +1,5 @@ use risc0_zkvm::{guest::env, serde::to_vec}; -use toy_example_core::{ +use core::{ account::Account, compute_nullifier, hash, input::InputVisibiility, is_in_tree, types::Nonce, }; diff --git a/risc0-selective-privacy-poc/src/lib.rs b/risc0-selective-privacy-poc/src/lib.rs index d1f98dd..f9b167f 100644 --- a/risc0-selective-privacy-poc/src/lib.rs +++ b/risc0-selective-privacy-poc/src/lib.rs @@ -1,12 +1,12 @@ -use outer_methods::{OUTER_ELF, OUTER_ID}; -use program::Program; -use rand::{rngs::OsRng, Rng}; -use risc0_zkvm::{default_executor, default_prover, ExecutorEnv, ExecutorEnvBuilder, Receipt}; -use toy_example_core::{ +use core::{ account::Account, input::InputVisibiility, types::{Commitment, Nonce, Nullifier}, }; +use outer_methods::{OUTER_ELF, OUTER_ID}; +use program::Program; +use rand::{rngs::OsRng, Rng}; +use risc0_zkvm::{default_executor, default_prover, ExecutorEnv, ExecutorEnvBuilder, Receipt}; pub mod program; diff --git a/risc0-selective-privacy-poc/transfer_methods/guest/Cargo.toml b/risc0-selective-privacy-poc/transfer_methods/guest/Cargo.toml index 81e568f..f1dffe8 100644 --- a/risc0-selective-privacy-poc/transfer_methods/guest/Cargo.toml +++ b/risc0-selective-privacy-poc/transfer_methods/guest/Cargo.toml @@ -1,5 +1,5 @@ [package] -name = "toy_example" +name = "transfer" version = "0.1.0" edition = "2021" @@ -7,4 +7,4 @@ edition = "2021" [dependencies] risc0-zkvm = { version = "2.2.0", default-features = false, features = ['std'] } -toy-example-core = {path = "../../core" } +core = { path = "../../core" } diff --git a/risc0-selective-privacy-poc/transfer_methods/guest/src/bin/transfer.rs b/risc0-selective-privacy-poc/transfer_methods/guest/src/bin/transfer.rs index 1fe7de8..f3f19b4 100644 --- a/risc0-selective-privacy-poc/transfer_methods/guest/src/bin/transfer.rs +++ b/risc0-selective-privacy-poc/transfer_methods/guest/src/bin/transfer.rs @@ -1,6 +1,9 @@ -use risc0_zkvm::{guest::env, sha::{Impl, Sha256}, serde::to_vec}; -use toy_example_core::account::Account; - +use core::account::Account; +use risc0_zkvm::{ + guest::env, + serde::to_vec, + sha::{Impl, Sha256}, +}; /// A transfer of balance program. /// To be used both in public and private contexts.