aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_hir/src/ty.rs
Commit message (Collapse)AuthorAgeFilesLines
...
* Fixup testsMarcus Klaas de Vries2019-01-141-21/+25
|
* don't try to treat arrays and tuples as literalsMarcus Klaas de Vries2019-01-141-29/+20
|
* Use type variables to determine exact type for ambiguous numeric literalsMarcus Klaas de Vries2019-01-141-6/+39
|
* Try implementing integer type inference (WIP)Marcus Klaas de Vries2019-01-141-26/+27
|
* Implement type inference for literals (WIP)Marcus Klaas de Vries2019-01-141-1/+32
|
* goto defenition works for type-inferred methodsAleksey Kladov2019-01-131-3/+22
|
* Implement tuple inferenceHirokazu Hata2019-01-131-0/+8
|
* args -> paramsFlorian Diebold2019-01-121-6/+6
|
* Implement basic inherent method resolutionFlorian Diebold2019-01-121-7/+32
|
* Fix assertion error in unification (hopefully)Florian Diebold2019-01-111-7/+33
| | | | | | | Currently, all types that we handle during inference need to be resolved as far as possible at the time. It's maybe too brittle of an invariant; I need to think how we can do this better. This should fix #484 though, I hope (if it's the same case as I managed to reproduce).
* actually produce missing def kindsAleksey Kladov2019-01-111-2/+6
|
* Implement type inference for enum variantsMarcus Klaas de Vries2019-01-101-6/+14
|
* nicer trailing comma handling in typesAleksey Kladov2019-01-091-9/+13
|
* Fix typos in ARCHITECTURE.md and a number of cratesMarcus Klaas de Vries2019-01-091-2/+2
| | | | specifically: gen_lsp_server, ra_arena, ra_cli, ra_db, ra_hir
* ra_db is independent from editorAleksey Kladov2019-01-081-0/+1
|
* Process explicit type hints for str, bool and charMarcus Klaas de Vries2019-01-071-1/+7
|
* Tidy up binary operator type inference; add test fileMarcus Klaas de Vries2019-01-071-44/+41
|
* Implement type inference for more binary operatorsMarcus Klaas de Vries2019-01-071-11/+74
| | | | | Mostly just for primitive numeric types such as u32 and f64. Not yet a general solution using trait resolution.
* Add remaining binary operations to ASTMarcus Klaas de Vries2019-01-071-0/+1
|
* Implement autoderef for field accessesFlorian Diebold2019-01-071-22/+50
|
* Introduce ArenaMapFlorian Diebold2019-01-061-12/+12
|
* Use HIR Expr for type inferenceFlorian Diebold2019-01-061-316/+228
| | | | | Now we can reuse the type inference inside a function when typing whitespace etc. :)
* Merge #440bors[bot]2019-01-061-2/+33
|\ | | | | | | | | | | | | | | | | | | 440: Implement type inference for boolean operators r=flodiebold a=marcusklaas Tried implementing the easiest part of https://github.com/rust-analyzer/rust-analyzer/issues/390. Hope this is somewhat close to what the intent of the issue was. Found it surprisingly easy to find my way around the repository - it's well organized! Very grateful for any pointers. Co-authored-by: Marcus Klaas de Vries <[email protected]>
| * Touch up type inference for boolean operatorsMarcus Klaas de Vries2019-01-061-7/+29
| | | | | | | | | | Also try to infer its subexpressions and set type expectations whenever possible.
| * Implement type inference for boolean operatorsMarcus Klaas de Vries2019-01-051-2/+11
| |
* | Make FnScopes use hir::ExprFlorian Diebold2019-01-051-13/+6
|/ | | | | | This was a bit complicated. I've added a wrapper type for now that does the LocalSyntaxPtr <-> ExprId translation; we might want to get rid of that or give it a nicer interface.
* Rename ImplBlock::target -> target_type, and add target_trait alreadyFlorian Diebold2019-01-041-2/+2
|
* Refactor a bitFlorian Diebold2019-01-041-58/+62
|
* Resolve the Self typeFlorian Diebold2019-01-041-21/+65
|
* Resolve the self parameter during type inferenceFlorian Diebold2019-01-041-2/+12
|
* Type the self parameterFlorian Diebold2019-01-041-7/+31
|
* Add more docs in ty.rsFlorian Diebold2018-12-291-19/+58
| | | | | Also get rid of the indirection through query_definitions for the type-related queries.
* Missing return type means unit, not unknownFlorian Diebold2018-12-291-1/+5
|
* Implement type variablesFlorian Diebold2018-12-291-111/+336
| | | | | | | | | This will really become necessary when we implement generics, but even now, it allows us to reason 'backwards' to infer types of expressions that we didn't understand for some reason. We use ena, the union-find implementation extracted from rustc, to keep track of type variables.
* nameify structs&enumsAleksey Kladov2018-12-281-17/+7
|
* introduce known namesAleksey Kladov2018-12-271-5/+4
|
* introduce hir::NameAleksey Kladov2018-12-271-5/+5
|
* Resolve field types lazilyFlorian Diebold2018-12-251-8/+28
| | | | I.e. not already when getting the HIR for the struct.
* Add a hir::TypeRef as an intermediate between ast::TypeRef and ty::TyFlorian Diebold2018-12-251-77/+62
|
* Implement reference / pointer typesFlorian Diebold2018-12-251-15/+69
| | | | | - parse them - infer types of & and * expressions
* Handle structs/enums with missing names a bit betterFlorian Diebold2018-12-251-6/+14
|
* CleanupFlorian Diebold2018-12-251-125/+37
|
* Implement basic completion for fieldsFlorian Diebold2018-12-251-2/+3
|
* Type field accessesFlorian Diebold2018-12-251-1/+31
|
* Collect field data for structs/enum variantsFlorian Diebold2018-12-251-1/+10
|
* Infer result of struct literals, and recurse into their child expressionsFlorian Diebold2018-12-251-36/+83
|
* Do name resolution by namespace (types/values)Florian Diebold2018-12-251-7/+15
|
* Add basic HIR and types for structs/enumsFlorian Diebold2018-12-251-26/+46
|
* Rename a variable for consistencyFlorian Diebold2018-12-241-9/+9
|
* Clean up Ty a bitFlorian Diebold2018-12-241-38/+22
| | | | Removing irrelevant comments copied from rustc etc.