Open nickysn opened 10 months ago
Adding #2629 for when this Epic is nearing completion
Added a "Bugs" section to the original Issue with latest ones @jfecher gathered.
Added https://github.com/noir-lang/noir/issues/3471 and https://github.com/noir-lang/noir/issues/3949. Useful features for Aztec.nr development.
I've made issues for all the remaining items. They are:
impl Trait
in a parameter position: https://github.com/noir-lang/noir/issues/4540<Type as Trait>
syntax: https://github.com/noir-lang/noir/issues/4539Of these, only #4538 is a major item. The rest are mostly small syntactic shorthands which would be nice to have. #4539 is to some degree necessary, but only once we have #4538.
This is a tracking issue for the implementation of traits.
Noir Traits Roadmap
Note: Traits are a huge feature, and this list is by no means final. Expect more steps to be added along the way.
Parser
Parser (optional)
Def collector
Name resolution/Type checking
Resolve types, defined inside a trait:
fn main() { let a: MyTrait::MyTraitType = ... }
Self::
https://github.com/noir-lang/noir/pull/2958self.
. Test: https://github.com/noir-lang/noir/pull/2918T::
(generic type) https://github.com/noir-lang/noir/pull/2958v.
(method invocation) (TODO: tests?)<TypeName as TraitName>::
TraitName::
(works only when the method has a Self parameter. Type inference is used to determine which implementation to use.)Monomorphization
Implement builtin traits
Testing