aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_hir/src/generics.rs
Commit message (Collapse)AuthorAgeFilesLines
* Publicise GenericParamsAleksey Kladov2019-11-181-3/+3
| | | | See https://rust-lang.zulipchat.com/#narrow/stream/185405-t-compiler.2Fwg-rls-2.2E0/topic/Exposing.20GenericParam.2Ename
* Refactor to unify with method resolutionFlorian Diebold2019-11-011-1/+2
|
* push name down to hir_expandAleksey Kladov2019-10-301-1/+1
|
* remove forward pointer for type_refAleksey Kladov2019-10-301-1/+1
|
* remove forward pointer to PathAleksey Kladov2019-10-301-2/+4
|
* remove forward pointer for nameAleksey Kladov2019-10-301-5/+9
|
* Support `$crate` in item and expr place.uHOOCCOOHu2019-09-261-0/+1
|
* Resolve trait associated itemsFlorian Diebold2019-09-251-6/+9
| | | | E.g. `Default::default` or `<Foo as Default>::default`.
* Handle associated type shorthand (`T::Item`)Florian Diebold2019-09-221-3/+8
| | | | | | | | | | | | This is only allowed for generic parameters (including `Self` in traits), and special care needs to be taken to not run into cycles while resolving it, because we use the where clauses of the generic parameter to find candidates for the trait containing the associated type, but the where clauses may themselves contain instances of short-hand associated types. In some cases this is even fine, e.g. we might have `T: Trait<U::Item>, U: Iterator`. If there is a cycle, we'll currently panic, which isn't great, but better than overflowing the stack...
* rename AdtDef -> AdtAleksey Kladov2019-09-121-9/+9
|
* generalize impl_froms to nested enumsAleksey Kladov2019-09-121-19/+8
|
* make various enums "inherit" from AdtDefAleksey Kladov2019-09-121-24/+25
|
* Lower bounds on trait definition, and resolve assoc types from super traitsFlorian Diebold2019-09-071-8/+14
|
* Add `impl Trait` and `dyn Trait` typesFlorian Diebold2019-08-221-14/+6
| | | | | | | - 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
* Don't add `?` bounds as real boundsAleksey Kladov2019-08-221-0/+8
| | | | closes #1709
* remove ast::*Kind from hirAleksey Kladov2019-08-191-2/+2
|
* migrate ra_hir to the new rowanAleksey Kladov2019-07-191-11/+11
|
* cargo formatMuhammad Mominul Huque2019-07-071-5/+1
|
* Constify KnownName'sMuhammad Mominul Huque2019-07-071-1/+2
|
* Make EnumVariant a GenericDef and simplify some codeFlorian Diebold2019-07-061-3/+9
|
* allow rustfmt to reorder importsAleksey Kladov2019-07-041-5/+6
| | | | | | This wasn't a right decision in the first place, the feature flag was broken in the last rustfmt release, and syntax highlighting of imports is more important anyway
* remove inherent source implsAleksey Kladov2019-06-111-1/+3
|
* use Source for impl blockAleksey Kladov2019-06-111-2/+2
|
* use Source for TraitAleksey Kladov2019-06-111-1/+1
|
* use Source for TypeAliasAleksey Kladov2019-06-111-1/+1
|
* use Source for FunctionAleksey Kladov2019-06-111-1/+1
|
* use Source moreAleksey Kladov2019-06-111-1/+1
|
* introduce Source structAleksey Kladov2019-06-111-1/+1
|
* add AstDatabaseAleksey Kladov2019-06-021-2/+2
|
* add union to code_modelAleksey Kladov2019-05-231-3/+10
|
* remove minor code duplicationAleksey Kladov2019-05-201-2/+2
|
* Add default type to GenericParamEdwin Cheng2019-05-191-3/+10
|
* Add support for inline boundsFlorian Diebold2019-05-111-16/+27
| | | | E.g. impl<T: Clone> Foo for T.
* Handle where clauses in trait solvingFlorian Diebold2019-05-111-3/+16
|
* Chalk integrationFlorian Diebold2019-05-041-1/+10
| | | | | - add proper canonicalization logic - add conversions from/to Chalk IR
* Add HIR for where clauses & ignore impls with where clauses in trait resolutionFlorian Diebold2019-04-211-2/+40
| | | | | This prevents any `impl<T> Trait for T where ...` from being treated as a blanket impl while we don't handle where clauses yet.
* Extract generic_params method to a HasGenericParams traitFlorian Diebold2019-04-141-0/+13
|
* Add Container enum to handle both kinds of container (impl/trait)Florian Diebold2019-04-141-7/+13
|
* More trait infrastructureFlorian Diebold2019-04-141-3/+7
| | | | | | | | | | - make it possible to get parent trait from method - add 'obligation' machinery for checking that a type implements a trait (and inferring facts about type variables from that) - handle type parameters of traits (to a certain degree) - improve the hacky implements check to cover enough cases to exercise the handling of traits with type parameters - basic canonicalization (will probably also be done by Chalk)
* Get substs for trait refs in impl blocksFlorian Diebold2019-04-141-1/+5
|
* rename persistent hir database -> def databaseAleksey Kladov2019-03-231-2/+2
|
* replace todo with fixmeAleksey Kladov2019-03-231-1/+1
|
* Rename Type => TypeAliasFlorian Diebold2019-02-241-5/+8
|
* Fix handling of generics in tuple variants and refactor a bitFlorian Diebold2019-02-201-0/+13
| | | | | | Also make them display a tiny bit nicer. Fixes #860.
* Handle impl generics in method callsFlorian Diebold2019-02-161-10/+28
|
* Add generic params to impl blocksFlorian Diebold2019-02-161-2/+4
|
* reformat the worldAleksey Kladov2019-02-081-8/+2
|
* Make the Resolution variants tuple variantsFlorian Diebold2019-02-011-0/+1
|
* split HirDatabase apicsmoe2019-02-011-2/+2
|
* Migrate trait & type to new idsAleksey Kladov2019-01-241-16/+7
|