aboutsummaryrefslogtreecommitdiff
path: root/crates/hir_ty
Commit message (Collapse)AuthorAgeFilesLines
...
| * Bump chalkLaurențiu Nicola2021-03-011-3/+3
|/
* Introduce Ty::AliasLukas Wirth2021-03-0113-94/+105
|
* Assert index relationship between type_variable_table and var_unification_tableLukas Wirth2021-03-012-22/+13
|
* Being Ty::InferenceVar closes to chalk equivalentLukas Wirth2021-03-0110-150/+170
|
* Merge #7816bors[bot]2021-02-288-81/+93
|\ | | | | | | | | | | | | | | 7816: Lift Ty::Fn into a struct r=Veykril a=Veykril bors r+ Co-authored-by: Lukas Wirth <[email protected]>
| * Lift FnPointer into a structLukas Wirth2021-02-288-81/+93
| |
* | hir_ty: use default type generic for box expressionscynecx2021-02-282-0/+61
|/
* Remove Substs from Ty::ForeignTypeLukas Wirth2021-02-285-18/+9
|
* Turn Ty::Tuple variant into a tuple-variantLukas Wirth2021-02-287-20/+18
|
* Fix code_model::Type::walk not walking all typesLukas Wirth2021-02-282-19/+18
|
* Inline TypeCtor into TyLukas Wirth2021-02-2815-832/+644
|
* Use chalk_ir::Scalar directlyLukas Wirth2021-02-286-197/+78
|
* Introduce TypeCtor::ScalarLukas Wirth2021-02-289-298/+271
|
* Add test from #7273Laurențiu Nicola2021-02-211-0/+45
|
* Bump depsLaurențiu Nicola2021-02-211-3/+3
|
* Don't write trailing whitespace when formatting empty GenericPredicatesLukas Wirth2021-02-202-11/+22
|
* Don't lower TypeBound::Lifetime as GenericPredicate::ErrorLukas Wirth2021-02-203-23/+21
|
* Add testLaurențiu Nicola2021-02-201-0/+24
|
* Wrap `BuiltinType` in code modelJonas Schievink2021-02-112-13/+11
|
* Add test for #1165Jonas Schievink2021-02-101-0/+29
| | | | Closes #1165
* Slightly expand testJonas Schievink2021-02-101-0/+3
|
* Add more testsJonas Schievink2021-02-102-8/+84
|
* Put the old resolver backJonas Schievink2021-02-101-3/+8
|
* Update fixed testsJonas Schievink2021-02-102-18/+20
|
* infer: update resolver when descending into blockJonas Schievink2021-02-102-16/+39
|
* Infra for "unit" benchmarkingAleksey Kladov2021-02-091-11/+12
|
* Merge #7602bors[bot]2021-02-082-11/+38
|\ | | | | | | | | | | | | | | 7602: Check for dyn impls in method resolution r=flodiebold a=Veykril Fixes #6777 Co-authored-by: Lukas Wirth <[email protected]>
| * Check for dyn impls in method resolutionLukas Wirth2021-02-082-11/+38
| |
* | Update crateskjeremy2021-02-082-5/+6
|/ | | | Pulls in https://github.com/rust-lang/chalk/pull/682
* Merge #7574bors[bot]2021-02-051-1/+1
|\ | | | | | | | | | | | | | | | | | | 7574: Remove various redundant clones r=kjeremy a=yoshuawuyts I noticed when running clippy through RA that there are a few instances where `clone` is called where it's not actually needed. I figured a small patch to remove these might be welcome here. Thanks! Co-authored-by: Yoshua Wuyts <[email protected]>
| * Remove redundant clonesYoshua Wuyts2021-02-051-1/+1
| |
| |
| \
*-. \ Merge #7570 #7571bors[bot]2021-02-052-161/+151
|\ \ \ | |_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 7570: Add doc gen to the `generate_enum_match_method` assist r=yoshuawuyts a=yoshuawuyts Implements a small extension to https://github.com/rust-analyzer/rust-analyzer/pull/7562, generating default comments. I wasn't sure if this would fit the goals of Rust-Analyzer, so I chose to split it into a separate PR. This is especially useful when writing code in a codebase which uses `#![warn(missing_docs)]` lint, as many production-grade libraries do. The comments we're generating here are similar to the ones found on [`Option::is_some`](https://doc.rust-lang.org/std/option/enum.Option.html#method.is_some) and [`Result::is_err`](https://doc.rust-lang.org/std/result/enum.Result.html#method.is_err). I briefly considered only generating these for `pub` types, but they seem small and unobtrusive enough that they're probably useful in the general case. Thanks! ## Example __input__ ```rust pub(crate) enum Variant { Undefined, Minor, // cursor here Major, } ``` __output__ ```rust pub(crate) enum Variant { Undefined, Minor, Major, } impl Variant { /// Returns `true` if the variant is [`Minor`]. pub(crate) fn is_minor(&self) -> bool { matches!(self, Self::Minor) } } ``` ## Future Directions This opens up the path to adding an assist for generating these comments on existing `is_` methods. This would make it both easy to document new code, and update existing code with documentation. 7571: Cleanup decl_check r=Veykril a=Veykril bors r+ Co-authored-by: Yoshua Wuyts <[email protected]> Co-authored-by: Lukas Wirth <[email protected]>
| | * Cleanup decl_checkLukas Wirth2021-02-052-161/+151
| |/
* / Remove unnecessary allocs in case_convLukas Wirth2021-02-051-18/+16
|/
* Make `ModPath`'s representation privateJonas Schievink2021-02-041-1/+1
|
* Use block_def_map in body loweringJonas Schievink2021-02-031-1/+1
|
* Bump chalkLaurențiu Nicola2021-02-022-5/+5
|
* Revert "Use block_def_map in body lowering"Jonas Schievink2021-02-021-1/+1
|
* Use block_def_map in body loweringJonas Schievink2021-02-011-1/+1
|
* Classify function calls as functions when shadowed by typesLukas Wirth2021-01-282-14/+17
|
* Bump depsLaurențiu Nicola2021-01-271-3/+3
|
* Create all `ModuleId`s through a `DefMap` methodJonas Schievink2021-01-251-1/+1
| | | | | `ModuleId` needs to be able to represent blocks, and only the associated `DefMap` will know how to construct that `ModuleId`
* Update tests to register the required standard library typesPhil Ellison2021-01-232-16/+48
|
* Fix test namesPhil Ellison2021-01-231-4/+4
|
* Identify methods using functions ids rather than string namesPhil Ellison2021-01-231-7/+27
|
* Implement fix, add testsPhil Ellison2021-01-232-28/+55
|
* Add diagnostic for filter_map followed by nextPhil Ellison2021-01-232-13/+105
|
* Make `ModuleId`'s `krate` field privateJonas Schievink2021-01-227-15/+17
|
* Obtain `ModuleId`'s `DefMap` through a methodJonas Schievink2021-01-221-3/+3
|
* Merge #7386bors[bot]2021-01-222-1/+28
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | 7386: Handle box with allocator r=flodiebold a=tweksteen In 1.49.0, the definition of Box was modified to support an optional Allocator[1]. Adapt the parsing of the `box` keyword to supply the expected number of parameters to the constructor. [1] https://github.com/rust-lang/rust/commit/f288cd2e179f600fa00c2a407206a12f6c5a91e0 Fixes: #6956 Co-authored-by: Thiébaud Weksteen <[email protected]>