From a8d7441c5963108376ad4ddf9b65ab8edb53cee1 Mon Sep 17 00:00:00 2001 From: Henry Hrvoje Tonkovac Date: Mon, 22 Jun 2026 15:11:46 +0200 Subject: [PATCH] main: trim qualified paths in lib Trim the one fully-qualified std::iter::successors path in the library crate down to an imported module, and drop the now-unnecessary crate-level #![expect(clippy::absolute_paths)]. Signed-off-by: Henry Hrvoje Tonkovac Assisted-by: Claude:Opus-4.8 --- cloud-hypervisor/src/lib.rs | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/cloud-hypervisor/src/lib.rs b/cloud-hypervisor/src/lib.rs index d2f3a6a4f..b8ba5847b 100644 --- a/cloud-hypervisor/src/lib.rs +++ b/cloud-hypervisor/src/lib.rs @@ -2,10 +2,8 @@ // // SPDX-License-Identifier: Apache-2.0 -// TODO: Trim qualified paths in this crate, then drop this expectation. -#![expect(clippy::absolute_paths)] - use std::error::Error; +use std::iter; use log::error; @@ -31,7 +29,7 @@ pub fn cli_print_error_chain<'a>( eprintln!(" {top_error}"); } else { eprintln!("chain of errors:"); - std::iter::successors(Some(top_error), |sub_error| { + iter::successors(Some(top_error), |sub_error| { // Dereference necessary to mitigate rustc compiler bug. // See (*sub_error).source()