816: Prelude & Edition 2015 import resolution r=matklad a=flodiebold
I implemented the prelude import, but it turned out to be useless without being able to resolve any of the imports in the prelude 😅 So I had to add some edition handling and handle 2015-style imports (at least the simplified scheme proposed in rust-lang/rust#57745). So now finally `Option` resolves 😄
One remaining problem is that we don't actually know the edition for sysroot crates. They're currently hardcoded to 2015, but there's already a bunch of PRs upgrading the editions of various rustc crates, so we'll have to detect the edition somehow, or just change the hardcoding to 2018 later, I guess...
~Also currently missing is completion for prelude names, though that shouldn't be hard to add. And `Vec` still doesn't resolve, so I need to look into that.~
Co-authored-by: Florian Diebold <flodiebold@gmail.com>
813: Add support for container_name in workspace/symbol query r=matklad a=vipentti
Currently this does not fill in the container_info if a type is defined on the top level in a file.
e.g. `foo.rs`
```rust
enum Foo { }
```
`Foo` will have None as the container_name, however
```rust
mod foo_mod {
enum Foo { }
}
```
`Foo` has `foo_mod` as the container_name.
This closes#559
Co-authored-by: Ville Penttinen <villem.penttinen@gmail.com>
814: auto_import: import in enclosing module by default r=matklad a=eulerdisk
Simpler version of #795
Co-authored-by: Andrea Pretto <eulerdisk@gmail.com>
815: Fix another crash r=matklad a=flodiebold
Found while typechecking rustc with better name resolution...
`walk_mut` doing a preorder walk can lead to an infinite recursion when substituting type parameters; postorder is actually what we want.
Co-authored-by: Florian Diebold <flodiebold@gmail.com>
807: Specify vscode 1.31 r=matklad a=kjeremy
This is for #796
It doesn't seem to fix the problem if you manually install the extension but it is the "right thing to do".
Co-authored-by: kjeremy <kjeremy@gmail.com>
781: Refactor to allow for multiple assists r=matklad a=eulerdisk
This is necessary to allow assist "providers" (which currently are simple free function) to produce multiple assists. I'm not sure this is the best possible refactoring tough.
Co-authored-by: Andrea Pretto <eulerdisk@gmail.com>