| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Now e.g.
```rust
fn a(b: [u8; 2]) {
}
```
will know about the length of b.
|
|/ |
|
|\
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
8799: Add basic support for array lengths in types r=flodiebold a=lf-
This recognizes `let a = [1u8, 2, 3]` as having type `[u8; 3]` instead
of the previous `[u8; _]`. Byte strings and `[0u8; 2]` kinds of range
array declarations are unsupported as before.
I don't know why a bunch of our rustc tests had single quotes inside
strings un-escaped by `UPDATE_EXPECT=1 cargo t`, but I don't think it's
bad? Maybe something in a nightly?
Co-authored-by: Jade <[email protected]>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This recognizes `let a = [1u8, 2, 3]` as having type `[u8; 3]` instead
of the previous `[u8; _]`. Byte strings and `[0u8; 2]` kinds of range
array declarations are unsupported as before.
I don't know why a bunch of our rustc tests had single quotes inside
strings un-escaped by `UPDATE_EXPECT=1 cargo t`, but I don't think it's
bad? Maybe something in a nightly?
|
|/ |
|
|
|
|
|
|
|
| |
This isn't actually how it works, you have to specify the exact trait
that has the associated type.
Fixes #8686.
|
| |
|
|
|
|
| |
closes #8604
|
|\
| |
| |
| |
| |
| |
| |
| | |
8462: Expand macros at type position r=jonas-schievink a=cynecx
Co-authored-by: cynecx <[email protected]>
|
| | |
|
| | |
|
| | |
|
|/ |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
| |
If we get lifetime variables back in autoderef, just immediately replace
them by static lifetimes for now. Method resolution doesn't really deal
correctly with new variables being introduced (this needs to be fixed
more properly).
This fixes `rust-analyzer analysis-stats --with-deps` crashing in the RA
repo.
|
|\
| |
| |
| |
| |
| |
| |
| | |
8394: Infer variants through type aliased enums r=Veykril a=Veykril
bors r+
Co-authored-by: Lukas Wirth <[email protected]>
|
| | |
|
|/ |
|
| |
|
| |
|
| |
|
| |
|
|\
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
7907: Autoderef with visibility r=cynecx a=cynecx
Fixes https://github.com/rust-analyzer/rust-analyzer/issues/7841.
I am not sure about the general approach here. Right now this simply tries to check whether the autoderef candidate is reachable from the current module. ~~However this doesn't exactly work with traits (see the `tests::macros::infer_derive_clone_in_core` test, which fails right now).~~ see comment below
Refs:
- `rustc_typeck` checking fields: https://github.com/rust-lang/rust/blob/66ec64ccf31883cd2c28d045912a76179c0c6ed2/compiler/rustc_typeck/src/check/expr.rs#L1610
r? @flodiebold
Co-authored-by: cynecx <[email protected]>
|
| | |
|
| | |
|
| | |
|
| | |
|
| | |
|
|\ \
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
8156: Correctly lower TraitRefs with default params r=flodiebold a=Veykril
Fixes #5685
Co-authored-by: Lukas Wirth <[email protected]>
|
| | | |
|
|/ / |
|
|\ \
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
8137: Fix box pattern inference panic r=flodiebold a=Veykril
Fixes #6560
Co-authored-by: Lukas Wirth <[email protected]>
|
| |/ |
|
|\ \
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
8134: Correct the paths of submodules from the include! macro r=edwin0cheng a=sticnarf
This PR should fix #7846. It mostly follows the instructions from @edwin0cheng in that issue.
Co-authored-by: Yilin Chen <[email protected]>
|
| |/
| |
| |
| | |
Signed-off-by: Yilin Chen <[email protected]>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This allows us to handle more cases without a query cycle, which
includes certain cases that rustc accepted. That in turn means we avoid
triggering salsa-rs/salsa#257 on valid code (it will still happen if the
user writes an actual cycle).
We actually accept more definitions than rustc now; that's because rustc
only ignores bindings when looking up super traits, whereas we now also
ignore them when looking for predicates to disambiguate associated type
shorthand. We could introduce a separate query for super traits if
necessary, but for now I think this should be fine.
|
|/ |
|
|
|
|
|
| |
Chalk doesn't have it, and judging from the removed code, it wasn't
useful anyway.
|
|\
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
8082: Proper handle inner recursive macro rules cases r=edwin0cheng a=edwin0cheng
Fixes #7645
cc @jonas-schievink
bors r+
Co-authored-by: Edwin Cheng <[email protected]>
|
| | |
|
| | |
|
|/ |
|
| |
|
| |
|