generic-const-exprs-panic-r.../binary/main.rs

15 lines
325 B
Rust
Raw Normal View History

2024-08-02 12:11:20 +10:00
use library::*;
fn main() {
// this doesn't compile
let mut inner = ImplementsTraitOverConstGeneric::<4>;
// but this would
// let mut inner = NonTraitWithConstGeneric::<4>;
// if we don't call this function then it'll compile fine
inner.configure(&Config {
config: [0, 0, 0, 0],
});
}