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 <htonkovac@gmail.com>
Assisted-by: Claude:Opus-4.8
This commit is contained in:
Henry Hrvoje Tonkovac
2026-06-22 15:11:46 +02:00
committed by Sebastien Boeuf
parent 1db8858fac
commit a8d7441c59

View File

@@ -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 <https://github.com/rust-lang/rust/issues/141673>
(*sub_error).source()