Remove TODOs

This commit is contained in:
Kirill Bulatov 2023-10-31 13:08:18 +02:00
parent 84c5494949
commit 6a3974ddbb

View file

@ -162,8 +162,7 @@ pub struct Project {
copilot_log_subscription: Option<lsp2::Subscription>, copilot_log_subscription: Option<lsp2::Subscription>,
current_lsp_settings: HashMap<Arc<str>, LspSettings>, current_lsp_settings: HashMap<Arc<str>, LspSettings>,
node: Option<Arc<dyn NodeRuntime>>, node: Option<Arc<dyn NodeRuntime>>,
// TODO kb uncomment #[cfg(not(any(test, feature = "test-support")))]
// #[cfg(not(any(test, feature = "test-support")))]
default_prettier: Option<DefaultPrettier>, default_prettier: Option<DefaultPrettier>,
prettier_instances: HashMap< prettier_instances: HashMap<
(Option<WorktreeId>, PathBuf), (Option<WorktreeId>, PathBuf),
@ -171,8 +170,7 @@ pub struct Project {
>, >,
} }
// TODO kb uncomment #[cfg(not(any(test, feature = "test-support")))]
// #[cfg(not(any(test, feature = "test-support")))]
struct DefaultPrettier { struct DefaultPrettier {
installation_process: Option<Shared<Task<()>>>, installation_process: Option<Shared<Task<()>>>,
installed_plugins: HashSet<&'static str>, installed_plugins: HashSet<&'static str>,
@ -688,8 +686,7 @@ impl Project {
copilot_log_subscription: None, copilot_log_subscription: None,
current_lsp_settings: ProjectSettings::get_global(cx).lsp.clone(), current_lsp_settings: ProjectSettings::get_global(cx).lsp.clone(),
node: Some(node), node: Some(node),
// TODO kb uncomment #[cfg(not(any(test, feature = "test-support")))]
// #[cfg(not(any(test, feature = "test-support")))]
default_prettier: None, default_prettier: None,
prettier_instances: HashMap::default(), prettier_instances: HashMap::default(),
} }
@ -792,8 +789,7 @@ impl Project {
copilot_log_subscription: None, copilot_log_subscription: None,
current_lsp_settings: ProjectSettings::get_global(cx).lsp.clone(), current_lsp_settings: ProjectSettings::get_global(cx).lsp.clone(),
node: None, node: None,
// TODO kb uncomment #[cfg(not(any(test, feature = "test-support")))]
// #[cfg(not(any(test, feature = "test-support")))]
default_prettier: None, default_prettier: None,
prettier_instances: HashMap::default(), prettier_instances: HashMap::default(),
}; };
@ -8568,19 +8564,18 @@ impl Project {
} }
} }
// TODO kb uncomment #[cfg(any(test, feature = "test-support"))]
// #[cfg(any(test, feature = "test-support"))] fn install_default_formatters(
// fn install_default_formatters( &mut self,
// &mut self, _: Option<WorktreeId>,
// _: Option<WorktreeId>, _: &Language,
// _: &Language, _: &LanguageSettings,
// _: &LanguageSettings, _: &mut ModelContext<Self>,
// _: &mut ModelContext<Self>, ) -> Task<anyhow::Result<()>> {
// ) -> Task<anyhow::Result<()>> { Task::ready(Ok(()))
// Task::ready(Ok(())) }
// }
// #[cfg(not(any(test, feature = "test-support")))] #[cfg(not(any(test, feature = "test-support")))]
fn install_default_formatters( fn install_default_formatters(
&mut self, &mut self,
worktree: Option<WorktreeId>, worktree: Option<WorktreeId>,