Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Public and private inputs to circuit function #76

Open
aleasims opened this issue Feb 15, 2024 · 0 comments
Open

Public and private inputs to circuit function #76

aleasims opened this issue Feb 15, 2024 · 0 comments
Assignees

Comments

@aleasims
Copy link
Contributor

We need to somehow specify publicity of arguments of circuit function: which arguments are public and which are private.

In C++ we now can do it by applying attributes to function arguments:

[[circuit]] void example(
    int a,                     // this is public input
    [[private_input]] int b,   // this is private input
);

Possible syntax of that in Rust is quite similar (using attributes on function parameters):

#[circuit]
fn example(
    a: u32,              // this is public input
    #[private] b: u32,   // this is private input
) {}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Development

No branches or pull requests

1 participant