#![feature(impl_trait_in_bindings)]
fn foo() {
let x: impl core::fmt::Debug = 12;
static x: impl core::fmt::Debug = 12;
const x: impl core::fmt::Debug = 12;
associated traits, quantification over traitsgadts(whereclauses on enum variants)AsRefinference limitations— some way to avoid the “every time I add an impl, code breaks” problem (probably opt-in, tied to the edition)GATsImplied boundsExistential types(centrilworking on fcp)Associated type defaultsSpecializationNeeds spec-level rework, possibly additional RFCAssociated type bound syntax improvementsNeeds testsInherent associated typesRe-re-balancing coherence
Named existential types
(workingon it)(done).let foo: impl Bar; / Impl Trait in Bindings
#![feature(impl_trait_in_bindings)]
fn foo() {
let x: impl core::fmt::Debug = 12;
static x: impl core::fmt::Debug = 12;
const x: impl core::fmt::Debug = 12;