2020-02-02 02:55:11 -06:00
|
|
|
trait Adapter {
|
|
|
|
const LINKS: usize;
|
|
|
|
}
|
|
|
|
|
|
|
|
struct Foo<A: Adapter> {
|
|
|
|
adapter: A,
|
|
|
|
links: [u32; A::LINKS], // Shouldn't suggest bounds already there.
|
2020-11-17 04:44:21 -06:00
|
|
|
//~^ ERROR generic parameters may not be used in const operations
|
2020-02-02 02:55:11 -06:00
|
|
|
}
|
|
|
|
|
|
|
|
fn main() {}
|