rust/crates
bors[bot] d7013a5934
Merge #7140
7140: Store trait associated items in fst r=matklad a=SomeoneToIgnore

Store imported traits' associated function/methods and constants into `ImportMap.fst` and pefrorm the imports search on them.

This is a first step towards trait autoimport during completion functionality, the way I see it, after this PR, only a few major things are left to be done:

* store all traits' assoc items into fst, not only the ones in scope, as we do now. Any code pointers on how to do this are welcome 😄 
* adjust a few modules in completions crate (`dot.rs`, `qualified_path.rs` at least) to query the import map, reusing the `import_assets` logic heavily

==
With the current import and autoimport implementations, it looks like for a single query, we're either interested in either associated items lookup or in all other `fst` contents lookup, but never both simultaneously.
I would rather not split `fst` in two but add another `Query` parameter to separate those, but let me know if you have any ideas.

Co-authored-by: Kirill Bulatov <mail4score@gmail.com>
2021-01-05 12:04:35 +00:00
..
arena Add TBD description to arena 2020-08-24 13:29:10 +02:00
assists Created an inline-function assist (fixes #6863) 2021-01-05 04:18:57 +08:00
base_db Add support for Rust 2021. 2021-01-01 17:22:23 +01:00
cfg Upgrade expect-test to 1.1 2021-01-03 14:43:29 +01:00
completion Small helpers 2021-01-04 22:01:35 +02:00
flycheck Pin cargo_metadata 2020-11-25 10:11:53 -05:00
hir Remove RetType 2021-01-04 20:34:23 +01:00
hir_def Merge #7140 2021-01-05 12:04:35 +00:00
hir_expand Refactor TokenBuffer for reduc cloning 2021-01-05 02:00:46 +08:00
hir_ty Update crates 2021-01-04 11:12:42 -05:00
ide Show GotoTypeAction for TypeParam 2021-01-04 15:54:45 +01:00
ide_db Code review fixes 2021-01-04 18:33:05 +02:00
mbe Simplify SubtreeTokenSource 2021-01-05 02:00:51 +08:00
parser parser,syntax: Add separate parser for stmt with optional semicolon 2021-01-03 12:05:52 +01:00
paths
proc_macro_api Remove serde_stacker which depends on cc 2021-01-01 15:26:55 +08:00
proc_macro_srv Fix spacing in proc-macro tokens to_string 2020-12-31 13:36:19 +08:00
proc_macro_test
profile Deny unreachable-pub 2020-11-02 14:07:08 +01:00
project_model Add support for Rust 2021. 2021-01-01 17:22:23 +01:00
rust-analyzer Allow #anchor linking of config options 2021-01-05 13:09:06 +03:00
ssr Merge #7147 2021-01-04 20:36:13 +00:00
stdx add open Cargo.toml action 2020-11-12 17:48:07 -08:00
syntax Update crates 2021-01-04 11:12:42 -05:00
test_utils Make config.rs a single source of truth for configuration. 2020-12-08 19:25:41 +03:00
text_edit Avoid turning completion objects into builders 2020-11-16 23:16:41 +02:00
toolchain
tt Refactor TokenBuffer for reduc cloning 2021-01-05 02:00:46 +08:00
vfs Merge #6785 2020-12-09 16:32:03 +00:00
vfs-notify Follow symlinks when walking project trees 2020-10-15 14:22:36 -04:00