-
Notifications
You must be signed in to change notification settings - Fork 119
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
Bug fixed. logic_or
should use LogicOrValueGate
#115
Conversation
I don't understand, why is there a impl<F> Gate<F> for LogicOrGate
where
F: Field,
{
fn name(&self) -> &'static str {
"Logic OR Gate"
}
fn q_lc(&self) -> [F; GATE_WIDTH] {
[F::one(), F::one(), F::zero(), F::zero()]
}
fn q_mul(&self) -> [F; N_MUL_SELECTORS] {
[-F::one(), F::zero()]
}
fn q_c(&self) -> F {
-F::one()
}
}
impl<F> Gate<F> for LogicOrValueGate
where
F: Field,
{
fn name(&self) -> &'static str {
"Logic OR Value Gate"
}
fn q_lc(&self) -> [F; GATE_WIDTH] {
[F::one(), F::one(), F::zero(), F::zero()]
}
fn q_mul(&self) -> [F; N_MUL_SELECTORS] {
[-F::one(), F::zero()]
}
fn q_o(&self) -> F {
F::one()
}
} basically |
I remember we used to have APIs |
Not really the same. For
We only have APIs |
@mrain Is there a better name for |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Description
closes: #114
Before we can merge this PR, please make sure that all the following items have been
checked off. If any of the checklist items are not applicable, please leave them but
write a little note why.
Updated relevant documentation in the codeAdded a relevant changelog entry to thePending
section inCHANGELOG.md
Files changed
in the GitHub PR explorer