From f1e1a2c0a79cc5cdab5ee6c6af21661d8e0731d8 Mon Sep 17 00:00:00 2001 From: Kirill Bulatov Date: Tue, 23 Mar 2021 19:04:48 +0200 Subject: Limit the hints size by default --- crates/rust-analyzer/src/config.rs | 4 ++-- docs/user/generated_config.adoc | 4 ++-- editors/code/package.json | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/crates/rust-analyzer/src/config.rs b/crates/rust-analyzer/src/config.rs index 5c88c3a9b..f49c4c33a 100644 --- a/crates/rust-analyzer/src/config.rs +++ b/crates/rust-analyzer/src/config.rs @@ -131,8 +131,8 @@ config_data! { /// Whether to show inlay type hints for method chains. inlayHints_chainingHints: bool = "true", - /// Maximum length for inlay hints. Default is unlimited. - inlayHints_maxLength: Option = "null", + /// Maximum length for inlay hints. Set to null to have an unlimited length. + inlayHints_maxLength: Option = "20", /// Whether to show function parameter name inlay hints at the call /// site. inlayHints_parameterHints: bool = "true", diff --git a/docs/user/generated_config.adoc b/docs/user/generated_config.adoc index c2521289c..6ea90f7af 100644 --- a/docs/user/generated_config.adoc +++ b/docs/user/generated_config.adoc @@ -206,10 +206,10 @@ Use markdown syntax for links in hover. -- Whether to show inlay type hints for method chains. -- -[[rust-analyzer.inlayHints.maxLength]]rust-analyzer.inlayHints.maxLength (default: `null`):: +[[rust-analyzer.inlayHints.maxLength]]rust-analyzer.inlayHints.maxLength (default: `20`):: + -- -Maximum length for inlay hints. Default is unlimited. +Maximum length for inlay hints. Set to null to have an unlimited length. -- [[rust-analyzer.inlayHints.parameterHints]]rust-analyzer.inlayHints.parameterHints (default: `true`):: + diff --git a/editors/code/package.json b/editors/code/package.json index faec45276..2b031aaa0 100644 --- a/editors/code/package.json +++ b/editors/code/package.json @@ -625,8 +625,8 @@ "type": "boolean" }, "rust-analyzer.inlayHints.maxLength": { - "markdownDescription": "Maximum length for inlay hints. Default is unlimited.", - "default": null, + "markdownDescription": "Maximum length for inlay hints. Set to null to have an unlimited length.", + "default": 20, "type": [ "null", "integer" -- cgit v1.2.3 From 5e83a56dfb69320b4fe3a980a1d1b79bab301894 Mon Sep 17 00:00:00 2001 From: Kirill Bulatov Date: Tue, 23 Mar 2021 19:43:55 +0200 Subject: Bump the default hint length --- crates/rust-analyzer/src/config.rs | 2 +- docs/user/generated_config.adoc | 2 +- editors/code/package.json | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/crates/rust-analyzer/src/config.rs b/crates/rust-analyzer/src/config.rs index f49c4c33a..cda272fd4 100644 --- a/crates/rust-analyzer/src/config.rs +++ b/crates/rust-analyzer/src/config.rs @@ -132,7 +132,7 @@ config_data! { /// Whether to show inlay type hints for method chains. inlayHints_chainingHints: bool = "true", /// Maximum length for inlay hints. Set to null to have an unlimited length. - inlayHints_maxLength: Option = "20", + inlayHints_maxLength: Option = "25", /// Whether to show function parameter name inlay hints at the call /// site. inlayHints_parameterHints: bool = "true", diff --git a/docs/user/generated_config.adoc b/docs/user/generated_config.adoc index 6ea90f7af..871c65add 100644 --- a/docs/user/generated_config.adoc +++ b/docs/user/generated_config.adoc @@ -206,7 +206,7 @@ Use markdown syntax for links in hover. -- Whether to show inlay type hints for method chains. -- -[[rust-analyzer.inlayHints.maxLength]]rust-analyzer.inlayHints.maxLength (default: `20`):: +[[rust-analyzer.inlayHints.maxLength]]rust-analyzer.inlayHints.maxLength (default: `25`):: + -- Maximum length for inlay hints. Set to null to have an unlimited length. diff --git a/editors/code/package.json b/editors/code/package.json index 2b031aaa0..d263610f5 100644 --- a/editors/code/package.json +++ b/editors/code/package.json @@ -626,7 +626,7 @@ }, "rust-analyzer.inlayHints.maxLength": { "markdownDescription": "Maximum length for inlay hints. Set to null to have an unlimited length.", - "default": 20, + "default": 25, "type": [ "null", "integer" -- cgit v1.2.3