From f31b101ce1e921a026ba234b1f0a83b0392bc118 Mon Sep 17 00:00:00 2001 From: nsfisis Date: Wed, 20 May 2026 08:33:49 +0900 Subject: fix(compile): fix all remaining compile errors Co-Authored-By: Claude Opus 4.7 (1M context) --- crates/shirabe/src/dependency_resolver/pool.rs | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'crates/shirabe/src/dependency_resolver/pool.rs') diff --git a/crates/shirabe/src/dependency_resolver/pool.rs b/crates/shirabe/src/dependency_resolver/pool.rs index a194d15..9b52ba7 100644 --- a/crates/shirabe/src/dependency_resolver/pool.rs +++ b/crates/shirabe/src/dependency_resolver/pool.rs @@ -214,7 +214,7 @@ impl Pool { /// Retrieves the package object for a given package id. pub fn package_by_id(&self, id: i64) -> &dyn BasePackage { - &self.packages[(id - 1) as usize] + self.packages[(id - 1) as usize].as_ref() } /// Searches all packages providing the given package name and match the constraint @@ -230,7 +230,7 @@ impl Pool { ) -> Vec> { // PHP: $key = (string) $constraint; let key = match constraint { - Some(c) => c.to_string(), + Some(c) => c.__to_string(), None => String::new(), }; if let Some(by_key) = self.provider_cache.get(name) { @@ -251,7 +251,7 @@ impl Pool { /// @param ?ConstraintInterface $constraint A constraint that all returned /// packages must match or null to return all /// @return BasePackage[] - fn compute_what_provides( + pub(crate) fn compute_what_provides( &self, name: &str, constraint: Option<&dyn ConstraintInterface>, @@ -281,11 +281,11 @@ impl Pool { pub fn literal_to_pretty_string( &self, literal: i64, - installed_map: &IndexMap>, + installed_map: &IndexMap>, ) -> String { let package = self.literal_to_package(literal); - let prefix = if installed_map.contains_key(&package.id()) { + let prefix = if installed_map.contains_key(&package.id().to_string()) { if literal > 0 { "keep" } else { "remove" } } else { if literal > 0 { @@ -316,7 +316,7 @@ impl Pool { || CompilingMatcher::r#match( constraint.unwrap(), Constraint::OP_EQ, - candidate_version, + candidate_version.to_string(), ); } -- cgit v1.3.1