noir-lang / noir

Noir is a domain specific language for zero knowledge proofs
https://noir-lang.org
Apache License 2.0
821 stars 177 forks source link

fix: ignore calls to `Intrinsic::AsWitness` during brillig codegen #5350

Closed TomAFrench closed 2 days ago

TomAFrench commented 2 days ago

Description

Problem*

Resolves

Summary*

This PR addresses an issue where if a call is made to std::as_witness from a brillig runtime then the compiler will panic with the unreachable error directly below where the new match arm is added.

Additional Context

Documentation*

Check one:

PR Checklist*