aboutsummaryrefslogtreecommitdiff
path: root/crates/hir_ty
Commit message (Collapse)AuthorAgeFilesLines
* Introduce anchored_pathAleksey Kladov2020-12-091-3/+5
| | | | | They allow to represent paths like `#[path = "C:\path.rs"] mod foo;` in a lossless cross-platform & network-transparent way.
* Upgrade ChalkFlorian Diebold2020-12-077-17/+129
| | | | | | | Also make overflow depth and max type size configurable through env variables. This can be helpful at least for debugging. Fixes #6628.
* Use correct, full substs for self type in implFlorian Diebold2020-12-042-1/+26
| | | | | | | | Without arbitrary self types, the self type could never refer to the method type parameters, so this wasn't a problem; but with arbitrary self types, it can. This fixes the crash from #6668; but it doesn't make method resolution work for these methods.
* Check structs for match exhaustivenessLukas Wirth2020-11-241-31/+120
|
* Add middle ellipsis missing arm textLukas Wirth2020-11-241-0/+14
|
* Handle ellipsis in tuple patterns in match exhaustiveness checkingLukas Wirth2020-11-241-42/+41
|
* Properly infer tuple struct patterns when encountering ellipsisLukas Wirth2020-11-242-9/+70
|
* Properly infer tuple patterns when encountering ellipsisLukas Wirth2020-11-242-8/+64
|
* Replace RacyFlag with OnceCellAleksey Kladov2020-11-112-3/+5
|
* Improve decl_check module readabilityIgor Aleksanov2020-11-031-6/+6
|
* Remove numbers from comments in decl_check.rsIgor Aleksanov2020-11-031-15/+15
|
* Check for allow(..) attributes for case diagnosticIgor Aleksanov2020-11-031-25/+91
|
* Bump chalk and lexerkjeremy2020-11-021-3/+3
|
* Remove more unreachable pubsAleksey Kladov2020-11-025-21/+21
|
* Deny unreachable-pubAleksey Kladov2020-11-029-67/+68
| | | | | | | | It's very useful when `pub` is equivalent to "this is crate's public API", let's enforce this! Ideally, we should enforce it for local `cargo test`, and only during CI, but that needs https://github.com/rust-lang/cargo/issues/5034.
* Upgrade Chalk to 0.36Florian Diebold2020-10-305-319/+179
| | | | Quite a few changes, because Chalk got rid of the `ApplicationTy` nesting.
* refactor(hir_ty): do not override DisplayTarget in hir_fmtBenjamin Coenen2020-10-281-45/+68
| | | | Signed-off-by: Benjamin Coenen <[email protected]>
* do not use associated types placeholder for inlay hintBenjamin Coenen2020-10-284-8/+17
| | | | Signed-off-by: Benjamin Coenen <[email protected]>
* do not use associated types placeholder for inlay hintBenjamin Coenen2020-10-283-60/+44
| | | | Signed-off-by: Benjamin Coenen <[email protected]>
* do not use associated types placeholder for inlay hintBenjamin Coenen2020-10-285-155/+87
| | | | Signed-off-by: Benjamin Coenen <[email protected]>
* do not use associated types placeholder for inlay hintBenjamin Coenen2020-10-282-31/+102
| | | | Signed-off-by: Benjamin Coenen <[email protected]>
* do not use associated types placeholder for inlay hint #6191Benjamin Coenen2020-10-273-19/+61
| | | | Signed-off-by: Benjamin Coenen <[email protected]>
* Fix case where non FnOnce variables is marked callableGrayJack2020-10-261-0/+13
|
* Merge #6350bors[bot]2020-10-261-126/+123
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | 6350: Make IncorrectDiagnostic match rustc by copying rustc's code. r=popzxc a=ArifRoktim This closes #6343 and closes #6345. The old algorithm which used a `DetectedCase` enum, didn't match how rustc thinks of cases. Some inputs can be interpreted as more than 1 case depending on the situation. For example, to rustc: - `ABCD`: Can be both camel case and upper snake case - `X86_64`: Can be both camel case and upper snake case I could've made `detect_case` return a collection of `DetectedCase` and then modified the other code as such, but I think using the same code rustc uses is simpler and a surefire way to achieve the same diagnostics as rustc. Co-authored-by: Arif Roktim <[email protected]>
| * Make IncorrectDiagnostic match rustc by copying rustc's code.Arif Roktim2020-10-251-126/+123
| |
* | Add tracing to main rust-analyzer binaryFlorian Diebold2020-10-251-1/+1
| |
* | Get rid of FAKE_PLACEHOLDERFlorian Diebold2020-10-251-8/+9
| | | | | | | | | | The lifetime placeholder can be replaced by the static lifetime, and for array sizes we should just be using a concrete const.
* | Bump chalkLaurențiu Nicola2020-10-241-3/+3
|/
* Improve Chalk debuggingFlorian Diebold2020-10-231-7/+23
| | | | | | - add panic context for the trait goal if CHALK_DEBUG is set - print the Chalk program even if we're panicking - log goal/solution while TLS is still set
* Merge #6319bors[bot]2020-10-222-3/+34
|\ | | | | | | | | | | | | | | 6319: Properly identify camel cased acronyms as UpperCamelCase r=popzxc a=ArifRoktim This closes #6305. Co-authored-by: Arif Roktim <[email protected]>
| * Properly identify camel cased acronyms as UpperCamelCaseArif Roktim2020-10-212-3/+34
| |
* | Merge #6307bors[bot]2020-10-211-0/+18
|\ \ | |/ |/| | | | | | | | | | | | | | | | | | | 6307: Add whitelist of safe intrinsics r=frazar a=frazar This PR should fix #5996, where intrinsic operations where all marked as unsafe. I'm rather new to this codebase, so I might be doing something *very* wrong. Please forgive me! In particular, I'm not sure how to "check that we are in extern `rust-intrinsics`" as mentioned [in this comment](https://github.com/rust-analyzer/rust-analyzer/issues/5996#issuecomment-709234802). Co-authored-by: Francesco Zardi <[email protected]>
| * Move safe intrinsic testsFrancesco Zardi2020-10-211-0/+18
| |
* | Add descriptions for diagnostics parseable by xtaskIgor Aleksanov2020-10-191-0/+55
|/
* binary operator overload type inference: add test markRoland Ruckerbauer2020-10-142-0/+6
|
* Implement binary operator overloading type inferenceRoland Ruckerbauer2020-10-133-5/+120
|
* Keep SyntaxNodePtr::range privateIgor Aleksanov2020-10-122-4/+13
|
* Replace 'if let' with 'match' in decl_check.rsIgor Aleksanov2020-10-121-30/+33
|
* Add to_upper_snake_case function to stdxIgor Aleksanov2020-10-122-4/+3
|
* Fix compilation errorIgor Aleksanov2020-10-121-2/+1
|
* Apply suggestions from code reviewIgor Aleksanov2020-10-121-2/+2
| | | Co-authored-by: Lukas Wirth <[email protected]>
* Fix code style issuesIgor Aleksanov2020-10-122-3/+7
|
* Fix issues with match arm bindingsIgor Aleksanov2020-10-121-7/+12
|
* Code style adjustmentsIgor Aleksanov2020-10-123-8/+88
|
* Make incorrect case diagnostic work inside of functionsIgor Aleksanov2020-10-122-33/+248
|
* Refactor string helpers for decl_check moduleIgor Aleksanov2020-10-121-32/+97
|
* Add diagnostics for enum names and variantsIgor Aleksanov2020-10-122-2/+147
|
* Add fix for incorrect case diagnosticIgor Aleksanov2020-10-121-1/+1
|
* Improve string helpers functionsIgor Aleksanov2020-10-121-1/+8
|
* Check structure fields to be snake_caseIgor Aleksanov2020-10-121-46/+65
|