From 4b109ec1a8fc4550150f56f0f46f2f41d844bda8 Mon Sep 17 00:00:00 2001 From: eldritch horrors Date: Tue, 9 Jul 2024 23:14:46 +0200 Subject: libstore: remove upcast_goal upcast_goal was only ever needed to break circular includes, but the same solution that gave us upcast_goal also lets us fully remove it: just upcast goals without a wrapper function, but only in .cc files. Change-Id: I9c71654b2535121459ba7dcfd6c5da5606904032 --- src/libstore/build/worker.hh | 15 --------------- 1 file changed, 15 deletions(-) (limited to 'src/libstore/build/worker.hh') diff --git a/src/libstore/build/worker.hh b/src/libstore/build/worker.hh index ba4cd88d7..e1d8e5031 100644 --- a/src/libstore/build/worker.hh +++ b/src/libstore/build/worker.hh @@ -17,21 +17,6 @@ struct DerivationGoal; struct PathSubstitutionGoal; class DrvOutputSubstitutionGoal; -/** - * Workaround for not being able to declare a something like - * - * ```c++ - * class PathSubstitutionGoal : public Goal; - * ``` - * even when Goal is a complete type. - * - * This is still a static cast. The purpose of exporting it is to define it in - * a place where `PathSubstitutionGoal` is concrete, and use it in a place where it - * is opaque. - */ -GoalPtr upcast_goal(std::shared_ptr subGoal); -GoalPtr upcast_goal(std::shared_ptr subGoal); - typedef std::chrono::time_point steady_time_point; /** -- cgit v1.2.3