aboutsummaryrefslogtreecommitdiff
path: root/crates/hir_ty
Commit message (Collapse)AuthorAgeFilesLines
...
| * Introduce HygieneFrames for proper token hygineeEdwin Cheng2021-01-021-0/+31
| |
* | Merge #7134bors[bot]2021-01-021-0/+18
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 7134: Fix infer error of macro invocation in array expr r=edwin0cheng a=edwin0cheng Fixed following infer error: ```rust macro_rules! bar { () => {0u32} } fn test() { let a = [bar!()]; // a : [unknown] } ``` bors r+ Co-authored-by: Edwin Cheng <edwin0cheng@gmail.com>
| * | Fix infer error of macro invocation in array exprEdwin Cheng2021-01-021-0/+18
| |/
* | Don't emit arg count diagnostics for method calls with unknown receiverFlorian Diebold2021-01-012-1/+29
| | | | | | | | Fixes #7098.
* | Merge #7080bors[bot]2021-01-014-5/+34
|\ \ | |/ |/| | | | | | | | | | | 7080: Implement ConstParams for HIR r=Veykril a=Veykril r? @flodiebold Co-authored-by: Lukas Wirth <lukastw97@gmail.com>
| * Add ConstParams to the ide layerLukas Wirth2021-01-011-1/+0
| |
| * Add ConstParams to the HIRLukas Wirth2021-01-014-5/+35
| |
* | Update crateskjeremy2020-12-301-1/+1
| |
* | Allow spurious warning from rust-lang/rust#80501Laurențiu Nicola2020-12-301-0/+2
|/
* Merge #7021bors[bot]2020-12-241-4/+4
|\ | | | | | | | | | | | | | | 7021: Track labels in the HIR r=matklad a=Veykril Groundwork for #6966 Co-authored-by: Lukas Wirth <lukastw97@gmail.com>
| * Track labels in the HIRLukas Wirth2020-12-241-4/+4
| |
* | Merge #7020bors[bot]2020-12-234-6/+45
|\ \ | | | | | | | | | | | | | | | | | | | | | 7020: Implement const pat and expr inference r=flodiebold a=Veykril Co-authored-by: Lukas Wirth <lukastw97@gmail.com>
| * | Implement const block inferenceLukas Wirth2020-12-232-5/+10
| | |
| * | Implement const pat inferenceLukas Wirth2020-12-232-1/+35
| |/
* / Bump chalkLaurențiu Nicola2020-12-232-5/+12
|/
* Higher-ranked trait bounds for where clausesLukas Wirth2020-12-172-12/+15
|
* decl_check: don't pass `db` around so oftenJonas Schievink2020-12-172-58/+60
|
* Make macro def krate mandatoryJonas Schievink2020-12-151-0/+6
| | | | Refactors builtin derive support to go through proper name resolution
* Move to upstream `macro_rules!` modelJonas Schievink2020-12-151-1/+0
|
* Add regression testEdwin Cheng2020-12-151-0/+24
|
* Add test for #6852Florian Diebold2020-12-131-0/+37
|
* Merge #6852bors[bot]2020-12-132-2/+13
|\ | | | | | | | | | | | | | | | | | | 6852: Ignore lifetime params in substitutions r=matklad a=Veykril [`hir_ty::utils::Generics`](https://github.com/rust-analyzer/rust-analyzer/blob/master/crates/hir_ty/src/utils.rs#L153) currently only assumes type parameters but not lifetime parameters and therefor creates incorrect index and length calculations, this PR just makes the use sites ignore LifetimeGenerics for now. This fixes the panic at least locally for me for `analysis-stats`. Funnily enough this panic prevented me from using reference search for the `args` field to fix this problem. Co-authored-by: Lukas Wirth <lukastw97@gmail.com>
| * Ignore lifetime params in substitutionsLukas Wirth2020-12-132-2/+13
| |
* | Merge #6845bors[bot]2020-12-121-1/+9
|\ \ | |/ |/| | | | | | | | | | | | | | | | | | | | | | | 6845: Don't HirDisplay unknown types when displaying for source r=Veykril a=Veykril Was wondering why the add missing impl assist didn't do anything here: ![Code_JCA1Qo0V9P](https://user-images.githubusercontent.com/3757771/101990300-7af44a80-3ca6-11eb-8431-e5eb4de4e78c.png) Turns out me forgetting to set the Index::Idx type in the trait causes RA to panic due to it trying to to create an unparsable type in the `make` module. Now we get this instead which imo is definitely better to have. ![Code_MUFPJUCULY](https://user-images.githubusercontent.com/3757771/101990347-c9094e00-3ca6-11eb-9c6a-146bddf64b7c.png) Co-authored-by: Lukas Wirth <lukastw97@gmail.com>
| * Don't HirDisplay unknown types when displaying for sourceLukas Wirth2020-12-121-1/+9
| |
* | Merge #6818bors[bot]2020-12-125-39/+77
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | 6818: Add Lifetimes to the HIR r=matklad a=Veykril This doesn't handle resolve yet as I don't know yet how that will be used. I'll get to that once I start moving the lifetime reference PR to the hir. This also adds a new `hir` name type for lifetimes and labels, `hir::LifetimeName`. Co-authored-by: Lukas Wirth <lukastw97@gmail.com>
| * | Add Lifetimes to the HIRLukas Wirth2020-12-115-39/+77
| |/
* | Added remove this semicolon testivan7702020-12-121-0/+10
| |
* | Infer labeled blocksLukas Wirth2020-12-112-4/+74
|/
* Merge #6769bors[bot]2020-12-102-3/+60
|\ | | | | | | | | | | | | | | | | | | 6769: Add native "remove this semicolon" diagnostics r=matklad a=ivan770 Closes #6739 ![demo2](https://user-images.githubusercontent.com/14003886/101530533-b76c3180-399a-11eb-9d18-5c8457721655.gif) Co-authored-by: ivan770 <leshenko.ivan770@gmail.com>
| * Cast to ExprStmt, style fixesivan7702020-12-101-6/+5
| |
| * Apply rustfmt changesivan7702020-12-091-9/+8
| |
| * Apply suggestions from code reviewivan7702020-12-091-17/+20
| | | | | | Co-authored-by: bjorn3 <bjorn3@users.noreply.github.com>
| * Format codeivan7702020-12-081-4/+13
| |
| * Remove use via superivan7702020-12-081-3/+1
| |
| * Remove this semicolonivan7702020-12-082-1/+50
| |
* | Use mark/hitJonas Schievink2020-12-101-0/+7
| |
* | Ignore extern items in incorrect-case checkJonas Schievink2020-12-101-0/+19
| |
* | Implement HirDisplay for FnSigJonas Schievink2020-12-091-20/+23
| | | | | | | | This could be useful for diagnostics, but isn't used right now
* | 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
|