From 5e31fa33c3b5cf726a57a063b8e7a070869250fe Mon Sep 17 00:00:00 2001 From: nsfisis Date: Tue, 19 May 2026 21:46:01 +0900 Subject: fix(compile): fix more random compile errors Co-Authored-By: Claude Opus 4.7 (1M context) --- .../shirabe/src/repository/installed_array_repository.rs | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) (limited to 'crates/shirabe/src/repository/installed_array_repository.rs') diff --git a/crates/shirabe/src/repository/installed_array_repository.rs b/crates/shirabe/src/repository/installed_array_repository.rs index c30d682..ddcda90 100644 --- a/crates/shirabe/src/repository/installed_array_repository.rs +++ b/crates/shirabe/src/repository/installed_array_repository.rs @@ -20,6 +20,16 @@ pub struct InstalledArrayRepository { } impl InstalledArrayRepository { + pub fn new() -> anyhow::Result { + Self::new_with_packages(Vec::new()) + } + + pub fn new_with_packages(packages: Vec>) -> anyhow::Result { + Ok(Self { + inner: WritableArrayRepository::new(packages)?, + }) + } + pub fn get_repo_name(&self) -> String { format!("installed {}", self.inner.get_repo_name()) } @@ -89,14 +99,14 @@ impl RepositoryInterface for InstalledArrayRepository { } fn find_package( &self, - _name: String, + _name: &str, _constraint: FindPackageConstraint, ) -> Option> { todo!() } fn find_packages( &self, - _name: String, + _name: &str, _constraint: Option, ) -> Vec> { todo!() -- cgit v1.3.1