Add impl Trait and dyn Trait types

- refactor bounds handling in the AST a bit
 - add HIR for bounds
 - add `Ty::Dyn` and `Ty::Opaque` variants and lower `dyn Trait` / `impl Trait`
   syntax to them
This commit is contained in:
Florian Diebold 2019-08-13 23:09:08 +02:00
parent 08e5d394df
commit 16a7d8cc85
8 changed files with 366 additions and 42 deletions

View file

@ -15,7 +15,7 @@ use crate::{
pub use self::{
expr_extensions::{ArrayExprKind, BinOp, ElseBranch, LiteralKind, PrefixOp},
extensions::{FieldKind, PathSegmentKind, SelfParamKind, StructKind},
extensions::{FieldKind, PathSegmentKind, SelfParamKind, StructKind, TypeBoundKind},
generated::*,
tokens::*,
traits::*,