// run-pass #![feature(generic_const_exprs)] #![allow(incomplete_features)] #![allow(dead_code)] trait Table: Sync { const COLUMNS: usize; } struct Table1; impl Table for Table1 { const COLUMNS: usize = 123; } struct Table2; impl Table for Table2 { const COLUMNS: usize = 456; } fn process_table, const D: usize>(_table: T) where [(); T::COLUMNS]:, { } fn process_all_tables() where [(); Table2::::COLUMNS]:, [(); Table1::::COLUMNS]:, { process_table(Table1::); process_table(Table2::); } fn main() {}