aboutsummaryrefslogtreecommitdiff
path: root/paludis/resolver/sanitised_dependencies.cc
diff options
context:
space:
mode:
authorAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2011-03-11 21:49:24 +0000
committerAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2011-03-11 21:49:24 +0000
commit5bc0738f9d8bf4085952e05961ff9380fa36e0c9 (patch)
tree4983a33ece2a522b93bd7b62cf60cdd27d1ab503 /paludis/resolver/sanitised_dependencies.cc
parent75a85b781c6e97e7c5df24a316b385a3aae76423 (diff)
downloadpaludis-5bc0738f9d8bf4085952e05961ff9380fa36e0c9.tar.gz
paludis-5bc0738f9d8bf4085952e05961ff9380fa36e0c9.tar.xz
Pool labels classifications
Diffstat (limited to 'paludis/resolver/sanitised_dependencies.cc')
-rw-r--r--paludis/resolver/sanitised_dependencies.cc8
1 files changed, 4 insertions, 4 deletions
diff --git a/paludis/resolver/sanitised_dependencies.cc b/paludis/resolver/sanitised_dependencies.cc
index d4f38ed..8439536 100644
--- a/paludis/resolver/sanitised_dependencies.cc
+++ b/paludis/resolver/sanitised_dependencies.cc
@@ -362,13 +362,13 @@ namespace
SanitisedDependency make_sanitised(const PackageOrBlockDepSpec & spec)
{
std::stringstream adl, acs;
- auto classifier(std::make_shared<LabelsClassifier>(env, our_id));
+ auto classifier_builder(std::make_shared<LabelsClassifierBuilder>(env, our_id));
for (DependenciesLabelSequence::ConstIterator i((*labels_stack.begin())->begin()),
i_end((*labels_stack.begin())->end()) ;
i != i_end ; ++i)
{
adl << (adl.str().empty() ? "" : ", ") << stringify(**i);
- (*i)->accept(*classifier);
+ (*i)->accept(*classifier_builder);
}
for (auto c(conditions_stack.begin()), c_end(conditions_stack.end()) ;
@@ -379,7 +379,7 @@ namespace
n::active_conditions_as_string() = acs.str(),
n::active_dependency_labels() = *labels_stack.begin(),
n::active_dependency_labels_as_string() = adl.str(),
- n::active_dependency_labels_classifier() = classifier,
+ n::active_dependency_labels_classifier() = classifier_builder->create(),
n::from_id() = our_id,
n::metadata_key_human_name() = human_name,
n::metadata_key_raw_name() = raw_name,
@@ -564,7 +564,7 @@ SanitisedDependency::deserialise(Deserialisation & d, const std::shared_ptr<cons
n::active_conditions_as_string() = v.member<std::string>("active_conditions_as_string"),
n::active_dependency_labels() = make_null_shared_ptr(),
n::active_dependency_labels_as_string() = v.member<std::string>("active_dependency_labels_as_string"),
- n::active_dependency_labels_classifier() = v.member<std::shared_ptr<LabelsClassifier> >("active_dependency_labels_classifier"),
+ n::active_dependency_labels_classifier() = v.member<std::shared_ptr<const LabelsClassifier> >("active_dependency_labels_classifier"),
n::from_id() = v.member<std::shared_ptr<const PackageID> >("from_id"),
n::metadata_key_human_name() = v.member<std::string>("metadata_key_human_name"),
n::metadata_key_raw_name() = v.member<std::string>("metadata_key_raw_name"),