noir-lang / noir

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

fix: fix incorrect return type being applied to stdlib functions `modulus_be_bytes()`, `modulus_be_bits()`, etc. #5278

Closed TomAFrench closed 3 months ago

TomAFrench commented 3 months ago

Description

Problem*

Resolves

Summary*

We're currently returning an array literal for these methods in the stdlib whereas the Noir code states that it should return a slice. This results in issues when passing these "slices" into other functions such that it causes the inlining pass to panic.

I've fixed this by replacing the array literal with a slice literal.

Additional Context

Documentation*

Check one:

PR Checklist*