Skip to content

Commit 3fb8acb

Browse files
Merge pull request #20050 from LHolten/better-docs-for-exclude-imports-in-symbol-search
Add better documentation for excluding imports from symbol search
2 parents 110bacd + af3f9d1 commit 3fb8acb

File tree

3 files changed

+11
-3
lines changed

3 files changed

+11
-3
lines changed

src/tools/rust-analyzer/crates/rust-analyzer/src/config.rs

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -762,7 +762,11 @@ config_data! {
762762
/// though Cargo might be the eventual consumer.
763763
vfs_extraIncludes: Vec<String> = vec![],
764764

765-
/// Exclude imports from symbol search.
765+
/// Exclude all imports from workspace symbol search.
766+
///
767+
/// In addition to regular imports (which are always excluded),
768+
/// this option removes public imports (better known as re-exports)
769+
/// and removes imports that rename the imported symbol.
766770
workspace_symbol_search_excludeImports: bool = false,
767771
/// Workspace symbol search kind.
768772
workspace_symbol_search_kind: WorkspaceSymbolSearchKindDef = WorkspaceSymbolSearchKindDef::OnlyTypes,

src/tools/rust-analyzer/docs/book/src/configuration_generated.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1542,7 +1542,11 @@ https://github.com/facebook/buck2/tree/main/integrations/rust-project.
15421542

15431543
Default: `false`
15441544

1545-
Exclude imports from symbol search.
1545+
Exclude all imports from workspace symbol search.
1546+
1547+
In addition to regular imports (which are always excluded),
1548+
this option removes public imports (better known as re-exports)
1549+
and removes imports that rename the imported symbol.
15461550

15471551

15481552
## rust-analyzer.workspace.symbol.search.kind {#workspace.symbol.search.kind}

src/tools/rust-analyzer/editors/code/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2905,7 +2905,7 @@
29052905
"title": "workspace",
29062906
"properties": {
29072907
"rust-analyzer.workspace.symbol.search.excludeImports": {
2908-
"markdownDescription": "Exclude imports from symbol search.",
2908+
"markdownDescription": "Exclude all imports from workspace symbol search.\n\nIn addition to regular imports (which are always excluded),\nthis option removes public imports (better known as re-exports)\nand removes imports that rename the imported symbol.",
29092909
"default": false,
29102910
"type": "boolean"
29112911
}

0 commit comments

Comments
 (0)