bors[bot] 1f897d1c6e
Merge #3120
3120: Support trait auto import r=matklad a=SomeoneToIgnore

Unfortunately, for real cases it does not work as spectacular as in the tests.

The main reason for that is type inference:
* The callee type [here](https://github.com/rust-analyzer/rust-analyzer/blob/master/crates/ra_hir_ty/src/method_resolution.rs#L369) is unknown for many cases
* The trait solution [here](https://github.com/rust-analyzer/rust-analyzer/blob/master/crates/ra_hir_ty/src/method_resolution.rs#L399) is also often ambiguous

That results in trait candidates being rejected, and some real cases not supported.
Example: no imports for `String::from_str("test")`

Co-authored-by: Kirill Bulatov <mail4score@gmail.com>
2020-02-13 11:37:32 +00:00
..
2020-02-12 23:27:19 +02:00
2020-01-31 21:07:21 +02:00
2020-02-05 12:47:28 +02:00
2020-02-12 17:34:37 +02:00
2020-02-11 21:46:36 +00:00
2020-02-12 18:02:00 +01:00
2020-02-07 14:26:59 +01:00
2020-02-02 18:56:37 +01:00
2020-02-12 23:15:48 +01:00
2020-02-10 01:57:43 +02:00