about summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2024-07-22 06:24:53 +0000
committerbors <bors@rust-lang.org>2024-07-22 06:24:53 +0000
commitf84d14e1c085de69261f4ef6ac483e0c58016f49 (patch)
tree295072c3eee70fd635437049345eb2bbfd74b358 /src
parent402e176f06f21d3bac348dbe09a2af689672b0c6 (diff)
parent3a5e7d9861ae96ad74f1d90b61422646add4f0ba (diff)
downloadrust-f84d14e1c085de69261f4ef6ac483e0c58016f49.tar.gz
rust-f84d14e1c085de69261f4ef6ac483e0c58016f49.zip
Auto merge of #17658 - alibektas:rename_get_field, r=Veykril
minor: Rename `config::get_field` to `config::get_field_json`
Diffstat (limited to 'src')
-rw-r--r--src/tools/rust-analyzer/crates/rust-analyzer/src/config.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/tools/rust-analyzer/crates/rust-analyzer/src/config.rs b/src/tools/rust-analyzer/crates/rust-analyzer/src/config.rs
index f3ee7a98ac6..6a3ccd10097 100644
--- a/src/tools/rust-analyzer/crates/rust-analyzer/src/config.rs
+++ b/src/tools/rust-analyzer/crates/rust-analyzer/src/config.rs
@@ -857,7 +857,7 @@ impl Config {
             tracing::info!("updating config from JSON: {:#}", json);
             if !(json.is_null() || json.as_object().map_or(false, |it| it.is_empty())) {
                 let mut json_errors = vec![];
-                let detached_files = get_field::<Vec<Utf8PathBuf>>(
+                let detached_files = get_field_json::<Vec<Utf8PathBuf>>(
                     &mut json,
                     &mut json_errors,
                     "detachedFiles",
@@ -2660,7 +2660,7 @@ macro_rules! _config_data {
 
             fn from_json(json: &mut serde_json::Value, error_sink: &mut Vec<(String, serde_json::Error)>) -> Self {
                 Self {$(
-                    $field: get_field(
+                    $field: get_field_json(
                         json,
                         error_sink,
                         stringify!($field),
@@ -2778,7 +2778,7 @@ impl GlobalLocalConfigInput {
     }
 }
 
-fn get_field<T: DeserializeOwned>(
+fn get_field_json<T: DeserializeOwned>(
     json: &mut serde_json::Value,
     error_sink: &mut Vec<(String, serde_json::Error)>,
     field: &'static str,