fix: add explicit type annotations for parse and remove unused imports
Co-authored-by: aider (openai/andrew/openrouter/deepseek/deepseek-chat-v3.1) <aider@aider.chat>
This commit is contained in:
@@ -1,4 +1,4 @@
|
|||||||
use anyhow::{anyhow, Context, Result};
|
use anyhow::{Context, Result};
|
||||||
use clap::Command;
|
use clap::Command;
|
||||||
use std::io::Read;
|
use std::io::Read;
|
||||||
use std::os::fd::FromRawFd;
|
use std::os::fd::FromRawFd;
|
||||||
@@ -146,7 +146,7 @@ fn write_item_to_pipe(
|
|||||||
compression_type: crate::compression_engine::CompressionType,
|
compression_type: crate::compression_engine::CompressionType,
|
||||||
pipe_writer_raw: std::fs::File,
|
pipe_writer_raw: std::fs::File,
|
||||||
) -> Result<(), anyhow::Error> {
|
) -> Result<(), anyhow::Error> {
|
||||||
use std::io::{BufWriter, BufReader};
|
use std::io::BufWriter;
|
||||||
|
|
||||||
let mut buffered_pipe_writer = BufWriter::new(pipe_writer_raw);
|
let mut buffered_pipe_writer = BufWriter::new(pipe_writer_raw);
|
||||||
|
|
||||||
@@ -305,8 +305,8 @@ pub fn mode_diff(
|
|||||||
let (item_path_a, item_path_b) = setup_diff_paths_and_compression(&item_service, &item_a, &item_b)?;
|
let (item_path_a, item_path_b) = setup_diff_paths_and_compression(&item_service, &item_a, &item_b)?;
|
||||||
|
|
||||||
// Get compression types from the items
|
// Get compression types from the items
|
||||||
let compression_type_a = item_a.item.compression.parse()?;
|
let compression_type_a: crate::compression_engine::CompressionType = item_a.item.compression.parse()?;
|
||||||
let compression_type_b = item_b.item.compression.parse()?;
|
let compression_type_b: crate::compression_engine::CompressionType = item_b.item.compression.parse()?;
|
||||||
|
|
||||||
let ((fd_a_read, fd_a_write), (fd_b_read, fd_b_write)) = setup_diff_pipes()?;
|
let ((fd_a_read, fd_a_write), (fd_b_read, fd_b_write)) = setup_diff_pipes()?;
|
||||||
let (_fd_a_read_guard, _fd_b_read_guard) = setup_fd_guards(fd_a_read, fd_b_read);
|
let (_fd_a_read_guard, _fd_b_read_guard) = setup_fd_guards(fd_a_read, fd_b_read);
|
||||||
|
|||||||
Reference in New Issue
Block a user