-
Notifications
You must be signed in to change notification settings - Fork 370
Labels
compiler frontend`noirc_frontend` crate`noirc_frontend` crate
Description
Aim
This code compiles but it probably should give some kind of error:
#[foo]
comptime fn foo(_: FunctionDefinition) -> Quoted {
let t = quote { [i32; 3] }.as_type();
quote {
struct Foo<$t> { // This should probably give an error
x: $t,
}
}
}
fn main() {
let _ = Foo::<i32> { x: [1, 2, 3] };
}I think the user case of interpolating a quoted type in a generic definition was to interpolate named generics from other types, but other kinds of types should give an error.
Expected Behavior
The compiler should give an error of some sort.
Bug
The compiler accepts the code.
To Reproduce
Workaround
None
Workaround Description
No response
Additional Context
No response
Project Impact
None
Blocker Context
No response
Nargo Version
No response
NoirJS Version
No response
Proving Backend Tooling & Version
No response
Would you like to submit a PR for this Issue?
None
Support Needs
No response
Metadata
Metadata
Assignees
Labels
compiler frontend`noirc_frontend` crate`noirc_frontend` crate