Closed michaeljklein closed 1 month ago
Attempted to compile the following program:
impl std::ops::Add<()> for () { fn add(self, other: ()) -> () { } } fn main() { }
The program to compile successfully
Compilation panics with:
❯ nargo compile The application panicked (crashed). Message: assertion `left == right` failed left: 0 right: 1 Location: compiler/noirc_frontend/src/elaborator/mod.rs:1526
1. 2. 3. 4.
None
No response
Binary (noirup default)
noirup
nargo version = 0.31.0 noirc version = 0.31.0+45e82a672b9ba7f7326e8d9f8800e2489013e2e8 (git version hash: 45e82a672b9ba7f7326e8d9f8800e2489013e2e8, is dirty: false)
Note this is because the Add trait is not generic.
Add
https://github.com/noir-lang/noir/blob/5bbce7977f72b07336bc8ef09f6acff687f1644a/compiler/noirc_frontend/src/elaborator/mod.rs#L1527
Aim
Attempted to compile the following program:
Expected Behavior
The program to compile successfully
Bug
Compilation panics with:
To Reproduce
1. 2. 3. 4.
Project Impact
None
Impact Context
No response
Workaround
None
Workaround Description
No response
Additional Context
No response
Installation Method
Binary (
noirup
default)Nargo Version
nargo version = 0.31.0 noirc version = 0.31.0+45e82a672b9ba7f7326e8d9f8800e2489013e2e8 (git version hash: 45e82a672b9ba7f7326e8d9f8800e2489013e2e8, is dirty: false)
NoirJS Version
No response
Would you like to submit a PR for this Issue?
None
Support Needs
No response