From abf5748f6426e86f62b4f91a352e6831fb367e15 Mon Sep 17 00:00:00 2001 From: Rob Bradford Date: Thu, 2 Jan 2025 15:38:32 +0000 Subject: [PATCH] block: qcow: Use constant in error message This avoids ambiguity of parameters: error: ambiguous reference to positional arguments by number in a tuple variant; change this to a named argument --> block/src/qcow/mod.rs:48:48 | 48 | #[error("File larger than max of {}: {0}", MAX_QCOW_FILE_SIZE)] | ^^^^^^^^^^^^^^^^^^ Signed-off-by: Rob Bradford --- block/src/qcow/mod.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/block/src/qcow/mod.rs b/block/src/qcow/mod.rs index e70488f13..802b73066 100644 --- a/block/src/qcow/mod.rs +++ b/block/src/qcow/mod.rs @@ -45,7 +45,7 @@ pub enum Error { CompressedBlocksNotSupported, #[error("Failed to evict cache: {0}")] EvictingCache(io::Error), - #[error("File larger than max of {}: {0}", MAX_QCOW_FILE_SIZE)] + #[error("File larger than max of {MAX_QCOW_FILE_SIZE}: {0}")] FileTooBig(u64), #[error("Failed to get file size: {0}")] GettingFileSize(io::Error),