rust-analyzer/crates/ide-completion/src
bors 34e2bc6a54 Auto merge of #13611 - yue4u:fix/completion-after-colon, r=yue4u
fix: filter unnecessary completions after colon

close #13597
related: #10173

This PR also happens to fix two extra issues:

1. The test case in https://github.com/rust-lang/rust-analyzer/blob/master/crates/ide-completion/src/tests/attribute.rs#L778-L801 was never triggered in previous behavior.

after:

https://user-images.githubusercontent.com/26110087/201476995-56adf955-0fa7-4f75-ab32-28a8e6cb9504.mp4

<del>
2. completions were triggered even in invalid paths, like

```rust
fn main() {
    core:::::$0
}
```

```rust
#[:::::$0]
struct X;
```

</del>

only `:::` is excluded as discussed in https://github.com/rust-lang/rust-analyzer/pull/13611#discussion_r1031845205
2022-11-26 17:55:00 +00:00
..
completions Strip comments and attributes off of all trait item completions 2022-11-15 12:41:39 +01:00
context fix: Fix item completions not working properly after unit structs and outline modules 2022-11-08 08:37:45 +01:00
render fix: Fix reference autocompletions using incorrect offsets in macro inputs 2022-08-23 14:29:59 +02:00
tests fix: also exclude 2 coloncolon in a row 2022-11-27 02:39:38 +09:00
completions.rs Add stub for cargo environment variables auto completion 2022-10-06 16:32:19 +02:00
config.rs Restructure find_path into a separate functions for modules and non-module items 2022-09-13 15:15:27 +02:00
context.rs fix: also exclude 2 coloncolon in a row 2022-11-27 02:39:38 +09:00
item.rs Record derive helper attributes, resolve them in IDE layer 2022-07-26 09:26:51 +02:00
lib.rs fix: filter unnecessary completions after colon 2022-11-12 22:33:40 +09:00
render.rs fix: Fix reference autocompletions using incorrect offsets in macro inputs 2022-08-23 14:29:59 +02:00
snippet.rs Restructure find_path into a separate functions for modules and non-module items 2022-09-13 15:15:27 +02:00
tests.rs Restructure find_path into a separate functions for modules and non-module items 2022-09-13 15:15:27 +02:00