mirror of
https://github.com/ProvableHQ/leo.git
synced 2024-12-25 03:04:13 +03:00
test pedersen hash constraint numbers
This commit is contained in:
parent
ae9ba51b7d
commit
f16bb70da9
@ -20,8 +20,6 @@ circuit PedersenHash {
|
||||
// The 'pedersen-hash' main function.
|
||||
function main(hash_input: [bool; 256], const parameters: [group; 256]) -> group {
|
||||
let pedersen = PedersenHash::new(parameters);
|
||||
let output = pedersen.hash(hash_input);
|
||||
console.log("{}", output);
|
||||
return output
|
||||
return pedersen.hash(hash_input)
|
||||
}
|
||||
|
||||
|
@ -113,19 +113,20 @@ impl<E: PairingEngine> ConstraintSystem<E::Fr> for CircuitSynthesizer<E> {
|
||||
}
|
||||
|
||||
fn pop_namespace(&mut self) {
|
||||
if let Some(ns) = self.namespaces.pop() {
|
||||
for idx in ns.constraint_indices {
|
||||
self.constraints.remove(idx);
|
||||
}
|
||||
|
||||
for idx in ns.private_var_indices {
|
||||
self.private_variables.remove(idx);
|
||||
}
|
||||
|
||||
for idx in ns.public_var_indices {
|
||||
self.public_variables.remove(idx);
|
||||
}
|
||||
}
|
||||
// Todo @ljedrz: Fix constraint system optimizations.
|
||||
// if let Some(ns) = self.namespaces.pop() {
|
||||
// for idx in ns.constraint_indices {
|
||||
// self.constraints.remove(idx);
|
||||
// }
|
||||
//
|
||||
// for idx in ns.private_var_indices {
|
||||
// self.private_variables.remove(idx);
|
||||
// }
|
||||
//
|
||||
// for idx in ns.public_var_indices {
|
||||
// self.public_variables.remove(idx);
|
||||
// }
|
||||
// }
|
||||
}
|
||||
|
||||
fn get_root(&mut self) -> &mut Self::Root {
|
||||
|
Loading…
Reference in New Issue
Block a user