diff --git a/crates/app/src/lib.rs b/crates/app/src/lib.rs index 6d4eafd5ae..3f2a0098cc 100644 --- a/crates/app/src/lib.rs +++ b/crates/app/src/lib.rs @@ -249,7 +249,7 @@ impl<'a> AppComponent<'a> { /// Returns an iterator of [`ContentPath`]s for this component's configured /// "directory mounts". - pub fn files(&self) -> std::slice::Iter { + pub fn files(&self) -> std::slice::Iter<'_, ContentPath> { self.locked.files.iter() } diff --git a/crates/componentize/src/lib.rs b/crates/componentize/src/lib.rs index e57ce131ef..76ee8f7a28 100644 --- a/crates/componentize/src/lib.rs +++ b/crates/componentize/src/lib.rs @@ -39,7 +39,7 @@ static EXPORT_INTERFACES: &[(&str, &str)] = &[ ("handle-http-request", "inbound-http"), ]; -pub fn componentize_if_necessary(module_or_component: &[u8]) -> Result> { +pub fn componentize_if_necessary(module_or_component: &[u8]) -> Result> { for payload in Parser::new(0).parse_all(module_or_component) { if let Payload::Version { encoding, .. } = payload.context("unable to parse binary")? { return match encoding { diff --git a/crates/componentize/src/module_info.rs b/crates/componentize/src/module_info.rs index c951b24432..5445004dba 100644 --- a/crates/componentize/src/module_info.rs +++ b/crates/componentize/src/module_info.rs @@ -83,7 +83,7 @@ impl ModuleInfo { /// Returns the wit-bindgen metadata producers processed-by field, if /// present. - pub fn bindgen_processors(&self) -> Option { + pub fn bindgen_processors(&self) -> Option> { self.bindgen .as_ref()? .producers diff --git a/crates/doctor/src/lib.rs b/crates/doctor/src/lib.rs index 1e40fe6a13..f98c069242 100644 --- a/crates/doctor/src/lib.rs +++ b/crates/doctor/src/lib.rs @@ -54,7 +54,7 @@ impl Checkup { } /// Returns the next detected problem. - pub async fn next_diagnosis(&mut self) -> Result> { + pub async fn next_diagnosis(&mut self) -> Result>> { while self.unprocessed_diagnoses.is_empty() { let Some(diagnostic) = self.diagnostics.pop_front() else { return Ok(None); diff --git a/crates/expressions/src/template.rs b/crates/expressions/src/template.rs index 013c897617..15973750c2 100644 --- a/crates/expressions/src/template.rs +++ b/crates/expressions/src/template.rs @@ -46,7 +46,7 @@ impl Template { self.parts.iter().all(|p| matches!(p, Part::Lit(_))) } - pub(crate) fn parts(&self) -> std::slice::Iter { + pub(crate) fn parts(&self) -> std::slice::Iter<'_, Part> { self.parts.iter() } } diff --git a/crates/factors-executor/src/lib.rs b/crates/factors-executor/src/lib.rs index 0737926949..cfdc704446 100644 --- a/crates/factors-executor/src/lib.rs +++ b/crates/factors-executor/src/lib.rs @@ -158,7 +158,7 @@ impl FactorsExecutorApp { } /// Returns an instance builder for the given component ID. - pub fn prepare(&self, component_id: &str) -> anyhow::Result> { + pub fn prepare(&self, component_id: &str) -> anyhow::Result> { let app_component = self .configured_app .app() @@ -204,7 +204,7 @@ pub struct FactorsInstanceBuilder<'a, F: RuntimeFactors, U: 'static> { impl FactorsInstanceBuilder<'_, T, U> { /// Returns the app component for the instance. - pub fn app_component(&self) -> &AppComponent { + pub fn app_component(&self) -> &AppComponent<'_> { &self.app_component } diff --git a/crates/factors/src/prepare.rs b/crates/factors/src/prepare.rs index c4f2401f66..f1d8c65ea2 100644 --- a/crates/factors/src/prepare.rs +++ b/crates/factors/src/prepare.rs @@ -65,7 +65,7 @@ impl<'a, T: RuntimeFactors, F: Factor> PrepareContext<'a, T, F> { } /// Get the app component. - pub fn app_component(&self) -> &'a AppComponent { + pub fn app_component(&self) -> &'a AppComponent<'_> { self.app_component } diff --git a/src/commands/watch.rs b/src/commands/watch.rs index a9a4cde600..a17f460fe0 100644 --- a/src/commands/watch.rs +++ b/src/commands/watch.rs @@ -338,7 +338,7 @@ impl watchexec::handler::Handler for NotifyOnFileChan _ = self.notifier.send(Uuid::new_v4()); } action.outcome(watchexec::action::Outcome::DoNothing); - Ok::<(), Box<(dyn std::error::Error + 'static)>>(()) + Ok::<(), Box>(()) } }