dev: add name for lookup

This commit is contained in:
Zhang Zhuo 2022-01-23 16:36:30 +08:00
parent e2a01d23db
commit 2a49e2a2bb
2 changed files with 3 additions and 4 deletions

View File

@ -226,6 +226,7 @@ impl fmt::Display for VerifyFailure {
"Lookup {}(index: {}) is not satisfied {}",
name, lookup_index, location
)
}
Self::Permutation { column, row } => {
write!(
f,
@ -1131,7 +1132,7 @@ mod tests {
let q = meta.complex_selector();
let table = meta.lookup_table_column();
meta.lookup(|cells| {
meta.lookup("lookup", |cells| {
let a = cells.query_advice(a, Rotation::cur());
let q = cells.query_selector(q);
@ -1208,6 +1209,7 @@ mod tests {
assert_eq!(
prover.verify(),
Err(vec![VerifyFailure::Lookup {
name: "lookup",
lookup_index: 0,
location: FailureLocation::InRegion {
region: (2, "Faulty synthesis").into(),

View File

@ -208,7 +208,4 @@ fn lookup_any() {
// the odd number lookup will fail.
let prover = MockProver::run(k, &circuit, vec![even_lookup]).unwrap();
assert!(prover.verify().is_err())
name: "odd number",
name: "odd number",
name: "odd number",
}