aboutsummaryrefslogtreecommitdiffhomepage
path: root/crates/shirabe/src/repository
diff options
context:
space:
mode:
authornsfisis <nsfisis@gmail.com>2026-06-07 14:15:55 +0900
committernsfisis <nsfisis@gmail.com>2026-06-07 14:15:55 +0900
commitda6f05c12d08ac96b4286664cd8205d3fee042d8 (patch)
tree7fb50447d73d04544edb224346604f294b450f95 /crates/shirabe/src/repository
parent86961b16b2f5c9c26a776193934d13ff87ab7fea (diff)
downloadphp-shirabe-da6f05c12d08ac96b4286664cd8205d3fee042d8.tar.gz
php-shirabe-da6f05c12d08ac96b4286664cd8205d3fee042d8.tar.zst
php-shirabe-da6f05c12d08ac96b4286664cd8205d3fee042d8.zip
feat(phase-c): resolve owned-argument phase-b TODOs
Replace value-by-value signature workarounds with proper ownership: - validate_json_schema: borrow JsonFile via ValidateJsonInput<&JsonFile>, restoring the dropped local auth file validation call - Auditor::audit / Solver::new / create_pool: pass cloned Rc handles and share Pool via Rc<RefCell<Pool>>; create_pool now takes &mut Request - MarkAlias{Installed,Uninstalled}Operation: hand over AliasPackageHandle from the alias-confirmed branch - dispatch_installer_event: clone the base Transaction (Rc-backed contents) and enable the PRE_OPERATIONS_EXEC dispatch - SuggestedPackagesReporter: share between command and installer via Rc<RefCell<>> to mirror PHP reference semantics PrePoolCreateEvent remains a TODO: it is plugin-only and would require a speculative Rc migration of Request whose payload is never read today.
Diffstat (limited to 'crates/shirabe/src/repository')
-rw-r--r--crates/shirabe/src/repository/repository_set.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/crates/shirabe/src/repository/repository_set.rs b/crates/shirabe/src/repository/repository_set.rs
index 62b25cb..aa5f128 100644
--- a/crates/shirabe/src/repository/repository_set.rs
+++ b/crates/shirabe/src/repository/repository_set.rs
@@ -459,7 +459,7 @@ impl RepositorySet {
/// @param list<string>|null $allowedTypes Only packages of those types are allowed if set to non-null
pub fn create_pool(
&mut self,
- mut request: Request,
+ request: &mut Request,
io: std::rc::Rc<std::cell::RefCell<dyn IOInterface>>,
event_dispatcher: Option<std::rc::Rc<std::cell::RefCell<EventDispatcher>>>,
pool_optimizer: Option<PoolOptimizer>,
@@ -518,7 +518,7 @@ impl RepositorySet {
self.locked = true;
- pool_builder.build_pool(self.repositories.clone(), &mut request)
+ pool_builder.build_pool(self.repositories.clone(), request)
}
/// Create a pool for dependency resolution from the packages in this repository set.
@@ -625,7 +625,7 @@ impl RepositorySet {
}
self.create_pool(
- request,
+ &mut request,
std::rc::Rc::new(std::cell::RefCell::new(NullIO::new())),
None,
None,