rust/crates
bors[bot] 46d7ee68f2
Merge #11865
11865: Fix: Select correct insert position for disabled group import r=jonasbb a=jonasbb

The logic for importing with and without `group_imports` differed
significantly when no previous group existed. This lead to the problem
of using the wrong position when importing inside a module (#11585) or
when inner attributes are involved.
The existing code for grouped imports is better and takes these things
into account.

This PR changes the flow to use the pre-existing code for adding a new
import group even for the non-grouped import settings.
Some coverage markers are updated and the `group` is removed, since they
are now invoked in both cases (grouping and no grouping).

Tests are updated and two tests (empty module and inner attribute) are
added.

Fixes #11585

Co-authored-by: Jonas Bushart <jonas@bushart.org>
2022-04-03 18:46:45 +00:00
..
base_db internal: Refactor FamousDefs builtin crate search 2022-03-30 22:23:54 +02:00
cfg minor: Bump dependencies 2022-03-22 17:42:24 +01:00
flycheck minor: Bump dependencies 2022-03-22 17:42:24 +01:00
hir internal: Remove PathResolution::AssocItem 2022-04-01 18:32:05 +02:00
hir_def suggest infered type in auto complete 2022-04-03 11:17:33 +04:30
hir_expand Type mismatch when last expression is noreturn asm 2022-03-30 19:07:02 +05:30
hir_ty fix: Don't rely on lang items to find primitive impls 2022-04-02 15:32:40 +02:00
ide Simplify completion import insertion 2022-04-02 01:42:21 +02:00
ide_assists Merge #11699 2022-04-03 12:42:52 +00:00
ide_completion add test for postfix completion relevance 2022-04-03 12:13:26 +01:00
ide_db Merge #11865 2022-04-03 18:46:45 +00:00
ide_diagnostics fix: Add missing fields diagnostic fix for patterns 2022-04-03 15:18:05 +02:00
ide_ssr internal: Remove PathResolution::AssocItem 2022-04-01 18:32:05 +02:00
limit
mbe minor: Bump dependencies 2022-03-22 17:42:24 +01:00
parser recover from missing type annotation 2022-04-01 17:20:54 +04:30
paths
proc_macro_api minor: Bump dependencies 2022-03-22 17:42:24 +01:00
proc_macro_srv fix comment 2022-03-25 15:30:52 +01:00
proc_macro_test minor: Bump dependencies 2022-03-22 17:42:24 +01:00
profile minor: Bump dependencies 2022-03-22 17:42:24 +01:00
project_model internal: Refactor FamousDefs builtin crate search 2022-03-30 22:23:54 +02:00
rust-analyzer Merge #10802 2022-04-03 12:03:46 +00:00
sourcegen Bump xshell and fix dist 2022-03-17 08:53:33 +02:00
stdx minor: Bump dependencies 2022-03-22 17:42:24 +01:00
syntax Merge #11887 2022-04-03 13:42:15 +00:00
test_utils Merge #11805 2022-03-23 20:20:09 +00:00
text_edit minor: Bump dependencies 2022-03-22 17:42:24 +01:00
toolchain
tt minor: Bump dependencies 2022-03-22 17:42:24 +01:00
vfs minor: Bump dependencies 2022-03-22 17:42:24 +01:00
vfs-notify minor: Bump dependencies 2022-03-22 17:42:24 +01:00