aboutsummaryrefslogtreecommitdiff
path: root/paludis/repositories
diff options
context:
space:
mode:
Diffstat (limited to 'paludis/repositories')
-rw-r--r--paludis/repositories/e/e_repository.cc4
-rw-r--r--paludis/repositories/e/e_repository_TEST.cc57
-rw-r--r--paludis/repositories/e/e_repository_TEST_0.cc51
-rw-r--r--paludis/repositories/e/e_repository_TEST_1.cc13
-rw-r--r--paludis/repositories/e/e_repository_TEST_2.cc19
-rw-r--r--paludis/repositories/e/e_repository_TEST_3.cc5
-rw-r--r--paludis/repositories/e/e_repository_TEST_4.cc47
-rw-r--r--paludis/repositories/e/e_repository_TEST_dependencies_rewriter.cc5
-rw-r--r--paludis/repositories/e/e_repository_TEST_ever.cc5
-rw-r--r--paludis/repositories/e/e_repository_TEST_exheres_0.cc113
-rw-r--r--paludis/repositories/e/e_repository_TEST_exlibs.cc5
-rw-r--r--paludis/repositories/e/e_repository_TEST_pbin.cc7
-rw-r--r--paludis/repositories/e/e_repository_TEST_phases.cc5
-rw-r--r--paludis/repositories/e/e_repository_TEST_replacing.cc7
-rw-r--r--paludis/repositories/e/e_repository_TEST_symlink_rewriting.cc5
-rw-r--r--paludis/repositories/e/e_repository_news.cc5
-rw-r--r--paludis/repositories/e/ebuild_flat_metadata_cache_TEST.cc93
-rw-r--r--paludis/repositories/e/exheres_profile.cc4
-rw-r--r--paludis/repositories/e/exndbam_repository_TEST.cc7
-rw-r--r--paludis/repositories/e/fetch_visitor_TEST.cc5
-rw-r--r--paludis/repositories/e/fix_locked_dependencies.cc4
-rw-r--r--paludis/repositories/e/info_metadata_key.cc5
-rw-r--r--paludis/repositories/e/pipe_command_handler.cc8
-rw-r--r--paludis/repositories/e/traditional_profile.cc11
-rw-r--r--paludis/repositories/e/vdb_repository.cc4
-rw-r--r--paludis/repositories/e/vdb_repository_TEST.cc60
-rw-r--r--paludis/repositories/e/vdb_unmerger_TEST.cc4
-rw-r--r--paludis/repositories/unpackaged/installed_repository_TEST.cc18
-rw-r--r--paludis/repositories/virtuals/virtuals_repository.cc4
29 files changed, 300 insertions, 280 deletions
diff --git a/paludis/repositories/e/e_repository.cc b/paludis/repositories/e/e_repository.cc
index d880933be..471d3acd4 100644
--- a/paludis/repositories/e/e_repository.cc
+++ b/paludis/repositories/e/e_repository.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2005, 2006, 2007, 2008, 2009, 2010 Ciaran McCreesh
+ * Copyright (c) 2005, 2006, 2007, 2008, 2009, 2010, 2011 Ciaran McCreesh
* Copyright (c) 2006 Danny van Dyk
*
* This file is part of the Paludis package manager. Paludis is free software;
@@ -670,7 +670,7 @@ ERepository::repository_masked(const std::shared_ptr<const PackageID> & id) cons
else
for (std::list<std::pair<std::shared_ptr<const PackageDepSpec>, std::shared_ptr<const RepositoryMaskInfo> > >::const_iterator
k(r->second.begin()), k_end(r->second.end()) ; k != k_end ; ++k)
- if (match_package(*_imp->params.environment(), *k->first, id, { }))
+ if (match_package(*_imp->params.environment(), *k->first, id, make_null_shared_ptr(), { }))
return k->second;
return std::shared_ptr<const RepositoryMaskInfo>();
diff --git a/paludis/repositories/e/e_repository_TEST.cc b/paludis/repositories/e/e_repository_TEST.cc
index 705970bd4..bdfe329e6 100644
--- a/paludis/repositories/e/e_repository_TEST.cc
+++ b/paludis/repositories/e/e_repository_TEST.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2006, 2007, 2008, 2009, 2010 Ciaran McCreesh
+ * Copyright (c) 2006, 2007, 2008, 2009, 2010, 2011 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -33,6 +33,7 @@
#include <paludis/util/set.hh>
#include <paludis/util/return_literal_function.hh>
#include <paludis/util/fs_stat.hh>
+#include <paludis/util/make_null_shared_ptr.hh>
#include <paludis/standard_output_manager.hh>
#include <paludis/util/safe_ifstream.hh>
#include <paludis/package_id.hh>
@@ -497,7 +498,7 @@ namespace test_cases
const std::shared_ptr<const PackageID> id1(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat-one/pkg-one-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(id1->end_metadata() != id1->find_metadata("EAPI"));
TEST_CHECK(simple_visitor_cast<const MetadataValueKey<std::string> >(**id1->find_metadata("EAPI")));
@@ -516,7 +517,7 @@ namespace test_cases
const std::shared_ptr<const PackageID> id2(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat-one/pkg-one-2",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(id2->end_metadata() != id2->find_metadata("EAPI"));
TEST_CHECK(bool(id2->short_description_key()));
@@ -532,7 +533,7 @@ namespace test_cases
const std::shared_ptr<const PackageID> id3(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat-one/pkg-one-3",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(id3->end_metadata() != id3->find_metadata("EAPI"));
TEST_CHECK(bool(id3->short_description_key()));
@@ -578,7 +579,7 @@ namespace test_cases
const std::shared_ptr<const PackageID> id1(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat-one/pkg-two-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(id1->end_metadata() != id1->find_metadata("EAPI"));
TEST_CHECK_EQUAL(std::static_pointer_cast<const erepository::ERepositoryID>(id1)->eapi()->name(), "UNKNOWN");
@@ -622,13 +623,13 @@ namespace test_cases
const std::shared_ptr<const PackageID> p1(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat-one/pkg-one-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
const std::shared_ptr<const PackageID> p2(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat-two/pkg-two-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
const std::shared_ptr<const PackageID> p4(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat-one/pkg-one-2",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
test_choice(p1, "flag1", true, true, false);
test_choice(p1, "flag2", false, false, true);
@@ -709,29 +710,29 @@ namespace test_cases
TEST_CHECK((*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=category/package-1::test-repo-18",
- &env, { })), { }))]->begin())->masked());
+ &env, { })), make_null_shared_ptr(), { }))]->begin())->masked());
TEST_CHECK((*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=category/package-2::test-repo-18",
- &env, { })), { }))]->begin())->masked());
+ &env, { })), make_null_shared_ptr(), { }))]->begin())->masked());
TEST_CHECK(! (*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=category/package-3::test-repo-18",
- &env, { })), { }))]->begin())->masked());
+ &env, { })), make_null_shared_ptr(), { }))]->begin())->masked());
TEST_CHECK(! (*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=category/package-4::test-repo-18",
- &env, { })), { }))]->begin())->masked());
+ &env, { })), make_null_shared_ptr(), { }))]->begin())->masked());
TEST_CHECK((*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=category/package-1::test-repo-19",
- &env, { })), { }))]->begin())->masked());
+ &env, { })), make_null_shared_ptr(), { }))]->begin())->masked());
TEST_CHECK(! (*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=category/package-2::test-repo-19",
- &env, { })), { }))]->begin())->masked());
+ &env, { })), make_null_shared_ptr(), { }))]->begin())->masked());
TEST_CHECK((*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=category/package-3::test-repo-19",
- &env, { })), { }))]->begin())->masked());
+ &env, { })), make_null_shared_ptr(), { }))]->begin())->masked());
TEST_CHECK(! (*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=category/package-4::test-repo-19",
- &env, { })), { }))]->begin())->masked());
+ &env, { })), make_null_shared_ptr(), { }))]->begin())->masked());
}
} test_e_repository_repository_masks;
@@ -759,13 +760,13 @@ namespace test_cases
TEST_CHECK((*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/masked-0",
- &env, { })), { }))]->begin())->masked());
+ &env, { })), make_null_shared_ptr(), { }))]->begin())->masked());
TEST_CHECK(! (*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/was_masked-0",
- &env, { })), { }))]->begin())->masked());
+ &env, { })), make_null_shared_ptr(), { }))]->begin())->masked());
TEST_CHECK(! (*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/not_masked-0",
- &env, { })), { }))]->begin())->masked());
+ &env, { })), make_null_shared_ptr(), { }))]->begin())->masked());
}
}
} test_e_repository_query_profile_masks;
@@ -944,7 +945,7 @@ namespace test_cases
TestMessageSuffix suffix("no files", true);
const std::shared_ptr<const PackageID> no_files_id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/no-files",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(no_files_id));
TEST_CHECK(bool(no_files_id->short_description_key()));
TEST_CHECK_EQUAL(no_files_id->short_description_key()->value(), "The Short Description");
@@ -955,7 +956,7 @@ namespace test_cases
TestMessageSuffix suffix("fetched files", true);
const std::shared_ptr<const PackageID> fetched_files_id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/fetched-files",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(fetched_files_id));
TEST_CHECK((FSPath("e_repository_TEST_dir") / "distdir" / "already-fetched.txt").stat().is_regular_file());
fetched_files_id->perform_action(action);
@@ -967,7 +968,7 @@ namespace test_cases
TEST_CHECK(! (FSPath("e_repository_TEST_dir") / "distdir" / "fetchable-1.txt").stat().is_regular_file());
const std::shared_ptr<const PackageID> fetchable_files_id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/fetchable-files",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(fetchable_files_id));
fetchable_files_id->perform_action(action);
TEST_CHECK((FSPath("e_repository_TEST_dir") / "distdir" / "fetchable-1.txt").stat().is_regular_file());
@@ -978,7 +979,7 @@ namespace test_cases
TEST_CHECK(! (FSPath("e_repository_TEST_dir") / "distdir" / "arrowed.txt").stat().is_regular_file());
const std::shared_ptr<const PackageID> arrow_files_id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/arrow-files",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(arrow_files_id));
arrow_files_id->perform_action(action);
TEST_CHECK((FSPath("e_repository_TEST_dir") / "distdir" / "arrowed.txt").stat().is_regular_file());
@@ -988,7 +989,7 @@ namespace test_cases
TestMessageSuffix suffix("unfetchable files", true);
const std::shared_ptr<const PackageID> unfetchable_files_id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/unfetchable-files",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(unfetchable_files_id));
TEST_CHECK_THROWS(unfetchable_files_id->perform_action(action), ActionFailedError);
}
@@ -996,7 +997,7 @@ namespace test_cases
{
const std::shared_ptr<const PackageID> no_files_restricted_id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/no-files-restricted",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(no_files_restricted_id));
no_files_restricted_id->perform_action(action);
}
@@ -1004,7 +1005,7 @@ namespace test_cases
{
const std::shared_ptr<const PackageID> fetched_files_restricted_id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/fetched-files-restricted",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(fetched_files_restricted_id));
fetched_files_restricted_id->perform_action(action);
}
@@ -1012,7 +1013,7 @@ namespace test_cases
{
const std::shared_ptr<const PackageID> fetchable_files_restricted_id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/fetchable-files-restricted",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(fetchable_files_restricted_id));
TEST_CHECK_THROWS(fetchable_files_restricted_id->perform_action(action), ActionFailedError);
}
@@ -1050,7 +1051,7 @@ namespace test_cases
const std::shared_ptr<const PackageID> id(*env[selection::AllVersionsSorted(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("category/package",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
repo->make_manifest(id->name());
id->perform_action(action);
diff --git a/paludis/repositories/e/e_repository_TEST_0.cc b/paludis/repositories/e/e_repository_TEST_0.cc
index bb18821aa..df8e925c2 100644
--- a/paludis/repositories/e/e_repository_TEST_0.cc
+++ b/paludis/repositories/e/e_repository_TEST_0.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2006, 2007, 2008, 2009, 2010 Ciaran McCreesh
+ * Copyright (c) 2006, 2007, 2008, 2009, 2010, 2011 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -30,6 +30,7 @@
#include <paludis/util/map.hh>
#include <paludis/util/make_named_values.hh>
#include <paludis/util/set.hh>
+#include <paludis/util/make_null_shared_ptr.hh>
#include <paludis/standard_output_manager.hh>
#include <paludis/util/safe_ifstream.hh>
#include <paludis/package_id.hh>
@@ -159,7 +160,7 @@ namespace test_cases
{
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=virtual/virtual-pretend-installed-0",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
}
#endif
@@ -168,7 +169,7 @@ namespace test_cases
TestMessageSuffix suffix("in-ebuild die", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/in-ebuild-die",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
}
@@ -177,7 +178,7 @@ namespace test_cases
TestMessageSuffix suffix("in-subshell die", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/in-subshell-die",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
}
@@ -186,7 +187,7 @@ namespace test_cases
TestMessageSuffix suffix("success", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/success",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
}
@@ -195,7 +196,7 @@ namespace test_cases
TestMessageSuffix suffix("unpack die", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/unpack-die",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
}
@@ -204,7 +205,7 @@ namespace test_cases
TestMessageSuffix suffix("econf die", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/econf-die",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
}
@@ -213,7 +214,7 @@ namespace test_cases
TestMessageSuffix suffix("emake fail", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/emake-fail",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
}
@@ -222,7 +223,7 @@ namespace test_cases
TestMessageSuffix suffix("emake die", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/emake-die",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
}
@@ -231,7 +232,7 @@ namespace test_cases
TestMessageSuffix suffix("einstall die", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/einstall-die",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
}
@@ -240,7 +241,7 @@ namespace test_cases
TestMessageSuffix suffix("keepdir die", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/keepdir-die",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
}
@@ -249,7 +250,7 @@ namespace test_cases
TestMessageSuffix suffix("dobin fail", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/dobin-fail",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
}
@@ -258,7 +259,7 @@ namespace test_cases
TestMessageSuffix suffix("dobin die", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/dobin-die",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
}
@@ -267,7 +268,7 @@ namespace test_cases
TestMessageSuffix suffix("fperms fail", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/fperms-fail",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
}
@@ -276,7 +277,7 @@ namespace test_cases
TestMessageSuffix suffix("fperms die", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/fperms-die",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
}
@@ -285,7 +286,7 @@ namespace test_cases
TestMessageSuffix suffix("econf source 0", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/econf-source-0",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "0");
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
@@ -295,7 +296,7 @@ namespace test_cases
TestMessageSuffix suffix("doman 0", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/doman-0",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "0");
id->perform_action(action);
@@ -305,7 +306,7 @@ namespace test_cases
TestMessageSuffix suffix("no src_prepare 0", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/src_prepare-0",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "0");
id->perform_action(action);
@@ -315,7 +316,7 @@ namespace test_cases
TestMessageSuffix suffix("no src_configure 0", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/src_configure-0",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "0");
id->perform_action(action);
@@ -325,7 +326,7 @@ namespace test_cases
TestMessageSuffix suffix("best version", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/best-version-0",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
}
@@ -334,7 +335,7 @@ namespace test_cases
TestMessageSuffix suffix("has version", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/has-version-0",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
}
@@ -343,7 +344,7 @@ namespace test_cases
TestMessageSuffix suffix("match", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/match-0",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
}
@@ -352,7 +353,7 @@ namespace test_cases
TestMessageSuffix suffix("vars", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/vars-0",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
}
@@ -361,7 +362,7 @@ namespace test_cases
TestMessageSuffix suffix("expand vars", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/expand-vars-0",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
}
@@ -370,7 +371,7 @@ namespace test_cases
TestMessageSuffix suffix("econf disable dependency tracking", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/econf-disable-dependency-tracking-0",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "0");
id->perform_action(action);
diff --git a/paludis/repositories/e/e_repository_TEST_1.cc b/paludis/repositories/e/e_repository_TEST_1.cc
index c786c2024..45a7094b9 100644
--- a/paludis/repositories/e/e_repository_TEST_1.cc
+++ b/paludis/repositories/e/e_repository_TEST_1.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2006, 2007, 2008, 2009, 2010 Ciaran McCreesh
+ * Copyright (c) 2006, 2007, 2008, 2009, 2010, 2011 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -30,6 +30,7 @@
#include <paludis/util/map.hh>
#include <paludis/util/make_named_values.hh>
#include <paludis/util/set.hh>
+#include <paludis/util/make_null_shared_ptr.hh>
#include <paludis/standard_output_manager.hh>
#include <paludis/util/safe_ifstream.hh>
#include <paludis/package_id.hh>
@@ -138,7 +139,7 @@ namespace test_cases
TestMessageSuffix suffix("econf source 1", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/econf-source-1",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "1");
id->perform_action(action);
@@ -148,7 +149,7 @@ namespace test_cases
TestMessageSuffix suffix("dosym success 1", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/dosym-success-1",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "1");
id->perform_action(action);
@@ -158,7 +159,7 @@ namespace test_cases
TestMessageSuffix suffix("doman 1", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/doman-1",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "1");
id->perform_action(action);
@@ -168,7 +169,7 @@ namespace test_cases
TestMessageSuffix suffix("no src_prepare 1", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/src_prepare-1",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "1");
id->perform_action(action);
@@ -178,7 +179,7 @@ namespace test_cases
TestMessageSuffix suffix("no src_configure 1", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/src_configure-1",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "1");
id->perform_action(action);
diff --git a/paludis/repositories/e/e_repository_TEST_2.cc b/paludis/repositories/e/e_repository_TEST_2.cc
index 768ff8072..c3484d74c 100644
--- a/paludis/repositories/e/e_repository_TEST_2.cc
+++ b/paludis/repositories/e/e_repository_TEST_2.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2006, 2007, 2008, 2009, 2010 Ciaran McCreesh
+ * Copyright (c) 2006, 2007, 2008, 2009, 2010, 2011 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -30,6 +30,7 @@
#include <paludis/util/map.hh>
#include <paludis/util/make_named_values.hh>
#include <paludis/util/set.hh>
+#include <paludis/util/make_null_shared_ptr.hh>
#include <paludis/standard_output_manager.hh>
#include <paludis/util/safe_ifstream.hh>
#include <paludis/package_id.hh>
@@ -138,7 +139,7 @@ namespace test_cases
TestMessageSuffix suffix("econf source 2", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/econf-source-2",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "2");
id->perform_action(action);
@@ -148,7 +149,7 @@ namespace test_cases
TestMessageSuffix suffix("doman 2", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/doman-2",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "2");
id->perform_action(action);
@@ -158,7 +159,7 @@ namespace test_cases
TestMessageSuffix suffix("src_prepare 2", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/src_prepare-2",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "2");
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
@@ -168,7 +169,7 @@ namespace test_cases
TestMessageSuffix suffix("src_configure 2", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/src_configure-2",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "2");
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
@@ -178,7 +179,7 @@ namespace test_cases
TestMessageSuffix suffix("default src_configure 2", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/default-src_configure-2",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "2");
id->perform_action(action);
@@ -188,7 +189,7 @@ namespace test_cases
TestMessageSuffix suffix("default src_compile 2", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/default-src_compile-2",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "2");
id->perform_action(action);
@@ -198,7 +199,7 @@ namespace test_cases
TestMessageSuffix suffix("default_src_compile 2", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/default_src_compile-2",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "2");
id->perform_action(action);
@@ -208,7 +209,7 @@ namespace test_cases
TestMessageSuffix suffix("src_compile via default function 2", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/src_compile-via-default-func-2",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "2");
id->perform_action(action);
diff --git a/paludis/repositories/e/e_repository_TEST_3.cc b/paludis/repositories/e/e_repository_TEST_3.cc
index 46942563e..aae03fe74 100644
--- a/paludis/repositories/e/e_repository_TEST_3.cc
+++ b/paludis/repositories/e/e_repository_TEST_3.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2006, 2007, 2008, 2009, 2010 Ciaran McCreesh
+ * Copyright (c) 2006, 2007, 2008, 2009, 2010, 2011 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -30,6 +30,7 @@
#include <paludis/util/map.hh>
#include <paludis/util/make_named_values.hh>
#include <paludis/util/set.hh>
+#include <paludis/util/make_null_shared_ptr.hh>
#include <paludis/standard_output_manager.hh>
#include <paludis/util/safe_ifstream.hh>
#include <paludis/package_id.hh>
@@ -138,7 +139,7 @@ namespace test_cases
TestMessageSuffix suffix("prefix", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/prefix-3",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "3");
id->perform_action(action);
diff --git a/paludis/repositories/e/e_repository_TEST_4.cc b/paludis/repositories/e/e_repository_TEST_4.cc
index b720681a3..4606a4379 100644
--- a/paludis/repositories/e/e_repository_TEST_4.cc
+++ b/paludis/repositories/e/e_repository_TEST_4.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2006, 2007, 2008, 2009, 2010 Ciaran McCreesh
+ * Copyright (c) 2006, 2007, 2008, 2009, 2010, 2011 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -31,6 +31,7 @@
#include <paludis/util/map.hh>
#include <paludis/util/make_named_values.hh>
#include <paludis/util/set.hh>
+#include <paludis/util/make_null_shared_ptr.hh>
#include <paludis/standard_output_manager.hh>
#include <paludis/util/safe_ifstream.hh>
#include <paludis/package_id.hh>
@@ -145,7 +146,7 @@ namespace test_cases
TestMessageSuffix suffix("pkg_pretend", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/pkg_pretend-4",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "4");
id->perform_action(pretend_action);
@@ -156,7 +157,7 @@ namespace test_cases
TestMessageSuffix suffix("pkg_pretend-failure", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/pkg_pretend-failure-4",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "4");
id->perform_action(pretend_action);
@@ -167,7 +168,7 @@ namespace test_cases
TestMessageSuffix suffix("default_src_install 4", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/default_src_install-4",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "4");
id->perform_action(action);
@@ -177,7 +178,7 @@ namespace test_cases
TestMessageSuffix suffix("docompress 4", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/docompress-4",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "4");
id->perform_action(action);
@@ -187,7 +188,7 @@ namespace test_cases
TestMessageSuffix suffix("dodoc -r", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/dodoc-r-4",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "4");
id->perform_action(action);
@@ -197,7 +198,7 @@ namespace test_cases
TestMessageSuffix suffix("doins symlink", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/doins-symlink-4",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "4");
id->perform_action(action);
@@ -207,7 +208,7 @@ namespace test_cases
TestMessageSuffix suffix("banned functions 4", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/banned-functions-4",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "4");
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
@@ -217,7 +218,7 @@ namespace test_cases
TestMessageSuffix suffix("econf disable dependency tracking", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/econf-disable-dependency-tracking-4",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "4");
id->perform_action(action);
@@ -227,7 +228,7 @@ namespace test_cases
TestMessageSuffix suffix("global scope use", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/global-scope-use-4",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "4");
id->perform_action(action);
@@ -237,7 +238,7 @@ namespace test_cases
TestMessageSuffix suffix("doman 4", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/doman-4",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "4");
id->perform_action(action);
@@ -303,7 +304,7 @@ namespace test_cases
TestMessageSuffix suffix("merge type source", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/merge-type-4::test-repo",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "4");
id->perform_action(action);
@@ -390,7 +391,7 @@ namespace test_cases
TestMessageSuffix suffix("merge type buildonly", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/merge-type-bin-4::test-repo",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "4");
id->perform_action(action);
@@ -409,7 +410,7 @@ namespace test_cases
TestMessageSuffix suffix("merge type binary", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/merge-type-bin-4::binrepo",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "pbin-1+4");
id->perform_action(action);
@@ -472,7 +473,7 @@ namespace test_cases
TestMessageSuffix suffix("all good", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/required-use-all-good-4::test-repo",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "4");
id->perform_action(pretend_action);
@@ -489,7 +490,7 @@ namespace test_cases
TestMessageSuffix suffix("all empty", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/required-use-all-empty-4::test-repo",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "4");
id->perform_action(pretend_action);
@@ -506,7 +507,7 @@ namespace test_cases
TestMessageSuffix suffix("all one not good", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/required-use-all-one-not-good-4::test-repo",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "4");
id->perform_action(pretend_action);
@@ -523,7 +524,7 @@ namespace test_cases
TestMessageSuffix suffix("any good", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/required-use-any-good-4::test-repo",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "4");
id->perform_action(pretend_action);
@@ -540,7 +541,7 @@ namespace test_cases
TestMessageSuffix suffix("any empty", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/required-use-any-empty-4::test-repo",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "4");
id->perform_action(pretend_action);
@@ -557,7 +558,7 @@ namespace test_cases
TestMessageSuffix suffix("any none", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/required-use-any-none-4::test-repo",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "4");
id->perform_action(pretend_action);
@@ -574,7 +575,7 @@ namespace test_cases
TestMessageSuffix suffix("one none", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/required-use-one-none-4::test-repo",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "4");
id->perform_action(pretend_action);
@@ -591,7 +592,7 @@ namespace test_cases
TestMessageSuffix suffix("one none", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/required-use-one-none-4::test-repo",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "4");
id->perform_action(pretend_action);
@@ -608,7 +609,7 @@ namespace test_cases
TestMessageSuffix suffix("one good", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/required-use-one-good-4::test-repo",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), "4");
id->perform_action(pretend_action);
diff --git a/paludis/repositories/e/e_repository_TEST_dependencies_rewriter.cc b/paludis/repositories/e/e_repository_TEST_dependencies_rewriter.cc
index b07f79ef9..5fd479cde 100644
--- a/paludis/repositories/e/e_repository_TEST_dependencies_rewriter.cc
+++ b/paludis/repositories/e/e_repository_TEST_dependencies_rewriter.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2006, 2007, 2008, 2009, 2010 Ciaran McCreesh
+ * Copyright (c) 2006, 2007, 2008, 2009, 2010, 2011 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -31,6 +31,7 @@
#include <paludis/util/map.hh>
#include <paludis/util/make_named_values.hh>
#include <paludis/util/set.hh>
+#include <paludis/util/make_null_shared_ptr.hh>
#include <paludis/standard_output_manager.hh>
#include <paludis/util/safe_ifstream.hh>
#include <paludis/package_id.hh>
@@ -106,7 +107,7 @@ namespace test_cases
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("category/package",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
UnformattedPrettyPrinter ff;
diff --git a/paludis/repositories/e/e_repository_TEST_ever.cc b/paludis/repositories/e/e_repository_TEST_ever.cc
index 1d0f418ee..40711ced3 100644
--- a/paludis/repositories/e/e_repository_TEST_ever.cc
+++ b/paludis/repositories/e/e_repository_TEST_ever.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2008, 2009, 2010 Ciaran McCreesh
+ * Copyright (c) 2008, 2009, 2010, 2011 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -30,6 +30,7 @@
#include <paludis/util/map.hh>
#include <paludis/util/make_named_values.hh>
#include <paludis/util/set.hh>
+#include <paludis/util/make_null_shared_ptr.hh>
#include <paludis/output_manager.hh>
#include <paludis/standard_output_manager.hh>
#include <paludis/package_id.hh>
@@ -158,7 +159,7 @@ namespace
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/" + test,
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
}
diff --git a/paludis/repositories/e/e_repository_TEST_exheres_0.cc b/paludis/repositories/e/e_repository_TEST_exheres_0.cc
index 8025b46ed..0772d3b4d 100644
--- a/paludis/repositories/e/e_repository_TEST_exheres_0.cc
+++ b/paludis/repositories/e/e_repository_TEST_exheres_0.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2006, 2007, 2008, 2009, 2010 Ciaran McCreesh
+ * Copyright (c) 2006, 2007, 2008, 2009, 2010, 2011 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -30,6 +30,7 @@
#include <paludis/util/map.hh>
#include <paludis/util/make_named_values.hh>
#include <paludis/util/set.hh>
+#include <paludis/util/make_null_shared_ptr.hh>
#include <paludis/standard_output_manager.hh>
#include <paludis/util/safe_ifstream.hh>
#include <paludis/package_id.hh>
@@ -157,7 +158,7 @@ namespace test_cases
TestMessageSuffix suffix("in-ebuild die", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/in-ebuild-die",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
}
@@ -166,7 +167,7 @@ namespace test_cases
TestMessageSuffix suffix("in-subshell die", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/in-subshell-die",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
}
@@ -175,7 +176,7 @@ namespace test_cases
TestMessageSuffix suffix("success", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/success",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
}
@@ -184,7 +185,7 @@ namespace test_cases
TestMessageSuffix suffix("expatch success", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/expatch-success",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
}
@@ -193,7 +194,7 @@ namespace test_cases
TestMessageSuffix suffix("expatch success-dir", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/expatch-success-dir",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
}
@@ -202,7 +203,7 @@ namespace test_cases
TestMessageSuffix suffix("expatch die", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/expatch-die",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
}
@@ -211,7 +212,7 @@ namespace test_cases
TestMessageSuffix suffix("expatch unrecognised", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/expatch-unrecognised",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
}
@@ -220,7 +221,7 @@ namespace test_cases
TestMessageSuffix suffix("nonfatal expatch fail", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/nonfatal-expatch-fail",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
}
@@ -229,7 +230,7 @@ namespace test_cases
TestMessageSuffix suffix("nonfatal expatch die", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/nonfatal-expatch-die",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
}
@@ -238,7 +239,7 @@ namespace test_cases
TestMessageSuffix suffix("unpack die", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/unpack-die",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
}
@@ -247,7 +248,7 @@ namespace test_cases
TestMessageSuffix suffix("nonfatal unpack fail", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/nonfatal-unpack-fail",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
}
@@ -256,7 +257,7 @@ namespace test_cases
TestMessageSuffix suffix("nonfatal unpack die", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/nonfatal-unpack-die",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
}
@@ -265,7 +266,7 @@ namespace test_cases
TestMessageSuffix suffix("econf fail", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/econf-fail",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
}
@@ -274,7 +275,7 @@ namespace test_cases
TestMessageSuffix suffix("nonfatal econf", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/nonfatal-econf",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
}
@@ -283,7 +284,7 @@ namespace test_cases
TestMessageSuffix suffix("nonfatal econf die", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/nonfatal-econf-die",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
}
@@ -292,7 +293,7 @@ namespace test_cases
TestMessageSuffix suffix("emake fail", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/emake-fail",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
}
@@ -301,7 +302,7 @@ namespace test_cases
TestMessageSuffix suffix("nonfatal emake", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/nonfatal-emake",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
}
@@ -310,7 +311,7 @@ namespace test_cases
TestMessageSuffix suffix("nonfatal emake die", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/nonfatal-emake-die",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
}
@@ -319,7 +320,7 @@ namespace test_cases
TestMessageSuffix suffix("einstall fail", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/einstall-fail",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
}
@@ -328,7 +329,7 @@ namespace test_cases
TestMessageSuffix suffix("nonfatal einstall", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/nonfatal-einstall",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
}
@@ -337,7 +338,7 @@ namespace test_cases
TestMessageSuffix suffix("nonfatal einstall die", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/nonfatal-einstall-die",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
}
@@ -346,7 +347,7 @@ namespace test_cases
TestMessageSuffix suffix("keepdir success", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/keepdir-success",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
}
@@ -355,7 +356,7 @@ namespace test_cases
TestMessageSuffix suffix("keepdir fail", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/keepdir-fail",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
}
@@ -364,7 +365,7 @@ namespace test_cases
TestMessageSuffix suffix("nonfatal keepdir", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/nonfatal-keepdir",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
}
@@ -373,7 +374,7 @@ namespace test_cases
TestMessageSuffix suffix("nonfatal keepdir die", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/nonfatal-keepdir-die",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
}
@@ -382,7 +383,7 @@ namespace test_cases
TestMessageSuffix suffix("dobin success", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/dobin-success",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
}
@@ -391,7 +392,7 @@ namespace test_cases
TestMessageSuffix suffix("dobin fail", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/dobin-fail",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
}
@@ -400,7 +401,7 @@ namespace test_cases
TestMessageSuffix suffix("nonfatal dobin success", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/nonfatal-dobin-success",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
}
@@ -409,7 +410,7 @@ namespace test_cases
TestMessageSuffix suffix("nonfatal dobin fail", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/nonfatal-dobin-fail",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
}
@@ -418,7 +419,7 @@ namespace test_cases
TestMessageSuffix suffix("nonfatal dobin die", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/nonfatal-dobin-die",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
}
@@ -427,7 +428,7 @@ namespace test_cases
TestMessageSuffix suffix("herebin success", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/herebin-success",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
}
@@ -436,7 +437,7 @@ namespace test_cases
TestMessageSuffix suffix("herebin fail", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/herebin-fail",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
}
@@ -445,7 +446,7 @@ namespace test_cases
TestMessageSuffix suffix("hereconfd success", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/hereconfd-success",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
}
@@ -454,7 +455,7 @@ namespace test_cases
TestMessageSuffix suffix("hereconfd fail", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/hereconfd-fail",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
}
@@ -463,7 +464,7 @@ namespace test_cases
TestMessageSuffix suffix("hereenvd success", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/hereenvd-success",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
}
@@ -472,7 +473,7 @@ namespace test_cases
TestMessageSuffix suffix("hereenvd fail", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/hereenvd-fail",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
}
@@ -481,7 +482,7 @@ namespace test_cases
TestMessageSuffix suffix("hereinitd success", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/hereinitd-success",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
}
@@ -490,7 +491,7 @@ namespace test_cases
TestMessageSuffix suffix("hereinitd fail", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/hereinitd-fail",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
}
@@ -499,7 +500,7 @@ namespace test_cases
TestMessageSuffix suffix("hereins success", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/hereins-success",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
}
@@ -508,7 +509,7 @@ namespace test_cases
TestMessageSuffix suffix("hereins fail", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/hereins-fail",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
}
@@ -517,7 +518,7 @@ namespace test_cases
TestMessageSuffix suffix("heresbin success", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/heresbin-success",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
}
@@ -526,7 +527,7 @@ namespace test_cases
TestMessageSuffix suffix("heresbin fail", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/heresbin-fail",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
}
@@ -535,7 +536,7 @@ namespace test_cases
TestMessageSuffix suffix("best version", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/best-version-0",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
}
@@ -544,7 +545,7 @@ namespace test_cases
TestMessageSuffix suffix("has version", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/has-version-0",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
}
@@ -553,7 +554,7 @@ namespace test_cases
TestMessageSuffix suffix("match", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/match-0",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
}
@@ -562,7 +563,7 @@ namespace test_cases
TestMessageSuffix suffix("econf phase", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/econf-phase-0",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
}
@@ -571,7 +572,7 @@ namespace test_cases
TestMessageSuffix suffix("econf vars", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/econf-vars-0",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
}
@@ -580,7 +581,7 @@ namespace test_cases
TestMessageSuffix suffix("expand vars", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/expand-vars-0",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
}
@@ -589,7 +590,7 @@ namespace test_cases
TestMessageSuffix suffix("doman success", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/doman-success-0",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
}
@@ -598,7 +599,7 @@ namespace test_cases
TestMessageSuffix suffix("doman nofatal", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/doman-nonfatal-0",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
}
@@ -607,7 +608,7 @@ namespace test_cases
TestMessageSuffix suffix("doman failure", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/doman-failure-0",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
}
@@ -616,7 +617,7 @@ namespace test_cases
TestMessageSuffix suffix("change globals", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/change-globals-0",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
}
@@ -625,7 +626,7 @@ namespace test_cases
TestMessageSuffix suffix("install", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/install-0",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
}
@@ -634,7 +635,7 @@ namespace test_cases
TestMessageSuffix suffix("install s", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/install-s-0",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
}
@@ -643,7 +644,7 @@ namespace test_cases
TestMessageSuffix suffix("global optionq", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/global-optionq-1",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_THROWS(id->perform_action(action), ActionFailedError);
}
diff --git a/paludis/repositories/e/e_repository_TEST_exlibs.cc b/paludis/repositories/e/e_repository_TEST_exlibs.cc
index 10ad171cf..1cc63723a 100644
--- a/paludis/repositories/e/e_repository_TEST_exlibs.cc
+++ b/paludis/repositories/e/e_repository_TEST_exlibs.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2008, 2009, 2010 Ciaran McCreesh
+ * Copyright (c) 2008, 2009, 2010, 2011 Ciaran McCreesh
* Copyright (c) 2009 Bo ├śrsted Andresen
*
* This file is part of the Paludis package manager. Paludis is free software;
@@ -31,6 +31,7 @@
#include <paludis/util/map.hh>
#include <paludis/util/make_named_values.hh>
#include <paludis/util/set.hh>
+#include <paludis/util/make_null_shared_ptr.hh>
#include <paludis/package_id.hh>
#include <paludis/metadata_key.hh>
#include <paludis/action.hh>
@@ -152,7 +153,7 @@ namespace
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/" + test,
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
switch (expected_result)
{
diff --git a/paludis/repositories/e/e_repository_TEST_pbin.cc b/paludis/repositories/e/e_repository_TEST_pbin.cc
index a940010cf..acd4cf9dc 100644
--- a/paludis/repositories/e/e_repository_TEST_pbin.cc
+++ b/paludis/repositories/e/e_repository_TEST_pbin.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2006, 2007, 2008, 2009, 2010 Ciaran McCreesh
+ * Copyright (c) 2006, 2007, 2008, 2009, 2010, 2011 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -31,6 +31,7 @@
#include <paludis/util/make_named_values.hh>
#include <paludis/util/set.hh>
#include <paludis/util/fs_stat.hh>
+#include <paludis/util/make_null_shared_ptr.hh>
#include <paludis/standard_output_manager.hh>
#include <paludis/util/safe_ifstream.hh>
#include <paludis/package_id.hh>
@@ -169,7 +170,7 @@ namespace test_cases
TestMessageSuffix suffix("prefix", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/simple-1",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(), base_eapi);
id->perform_action(bin_action);
@@ -190,7 +191,7 @@ namespace test_cases
TestMessageSuffix suffix("prefix", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/simple-1::binrepo" + base_eapi,
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(simple_visitor_cast<const MetadataValueKey<std::string> >(**id->find_metadata("EAPI"))->value(),
"pbin-1+" + base_eapi);
diff --git a/paludis/repositories/e/e_repository_TEST_phases.cc b/paludis/repositories/e/e_repository_TEST_phases.cc
index ef73cbc0b..b8cb0a43f 100644
--- a/paludis/repositories/e/e_repository_TEST_phases.cc
+++ b/paludis/repositories/e/e_repository_TEST_phases.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2008, 2009, 2010 Ciaran McCreesh
+ * Copyright (c) 2008, 2009, 2010, 2011 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -30,6 +30,7 @@
#include <paludis/util/map.hh>
#include <paludis/util/make_named_values.hh>
#include <paludis/util/set.hh>
+#include <paludis/util/make_null_shared_ptr.hh>
#include <paludis/output_manager.hh>
#include <paludis/standard_output_manager.hh>
#include <paludis/package_id.hh>
@@ -168,7 +169,7 @@ namespace
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/" + test,
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
TEST_CHECK_EQUAL(!! id->choices_key()->value()->find_by_name_with_prefix(
ChoiceNameWithPrefix("build_options:expensive_tests")), expect_expensive_test);
diff --git a/paludis/repositories/e/e_repository_TEST_replacing.cc b/paludis/repositories/e/e_repository_TEST_replacing.cc
index e873be448..53b4b12ce 100644
--- a/paludis/repositories/e/e_repository_TEST_replacing.cc
+++ b/paludis/repositories/e/e_repository_TEST_replacing.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2009, 2010 Ciaran McCreesh
+ * Copyright (c) 2009, 2010, 2011 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -26,6 +26,7 @@
#include <paludis/util/make_named_values.hh>
#include <paludis/util/set.hh>
#include <paludis/util/map.hh>
+#include <paludis/util/make_null_shared_ptr.hh>
#include <paludis/package_id.hh>
#include <paludis/metadata_key.hh>
#include <paludis/action.hh>
@@ -143,7 +144,7 @@ namespace
const std::shared_ptr<const PackageIDSequence> rlist(env[selection::AllVersionsSorted(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec(replacing, &env, { })),
- { }) |
+ make_null_shared_ptr(), { }) |
filter::InstalledAtRoot(env.preferred_root_key()->value()))]);
InstallAction action(make_named_values<InstallActionOptions>(
@@ -156,7 +157,7 @@ namespace
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/" + test,
- &env, { })), { }) |
+ &env, { })), make_null_shared_ptr(), { }) |
filter::SupportsAction<InstallAction>())]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
diff --git a/paludis/repositories/e/e_repository_TEST_symlink_rewriting.cc b/paludis/repositories/e/e_repository_TEST_symlink_rewriting.cc
index afec5f7c6..e92c754c3 100644
--- a/paludis/repositories/e/e_repository_TEST_symlink_rewriting.cc
+++ b/paludis/repositories/e/e_repository_TEST_symlink_rewriting.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2006, 2007, 2008, 2009, 2010 Ciaran McCreesh
+ * Copyright (c) 2006, 2007, 2008, 2009, 2010, 2011 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -32,6 +32,7 @@
#include <paludis/util/set.hh>
#include <paludis/standard_output_manager.hh>
#include <paludis/util/safe_ifstream.hh>
+#include <paludis/util/make_null_shared_ptr.hh>
#include <paludis/package_id.hh>
#include <paludis/metadata_key.hh>
#include <paludis/action.hh>
@@ -140,7 +141,7 @@ namespace test_cases
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("cat/pkg",
- &env, { })), { }))]->last());
+ &env, { })), make_null_shared_ptr(), { }))]->last());
TEST_CHECK(bool(id));
id->perform_action(action);
diff --git a/paludis/repositories/e/e_repository_news.cc b/paludis/repositories/e/e_repository_news.cc
index da7df1e91..d37d1fca6 100644
--- a/paludis/repositories/e/e_repository_news.cc
+++ b/paludis/repositories/e/e_repository_news.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2006, 2007, 2008, 2009, 2010 Ciaran McCreesh
+ * Copyright (c) 2006, 2007, 2008, 2009, 2010, 2011 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -33,6 +33,7 @@
#include <paludis/util/fs_path.hh>
#include <paludis/util/fs_stat.hh>
#include <paludis/util/fs_iterator.hh>
+#include <paludis/util/make_null_shared_ptr.hh>
#include <paludis/environment.hh>
#include <paludis/distribution.hh>
@@ -177,7 +178,7 @@ ERepositoryNews::update_news() const
generator::Matches(PackageDepSpec(parse_elike_package_dep_spec(*i,
eapi.supported()->package_dep_spec_parse_options(),
eapi.supported()->version_spec_options(),
- std::shared_ptr<const PackageID>())), { }) |
+ std::shared_ptr<const PackageID>())), make_null_shared_ptr(), { }) |
filter::InstalledAtRoot(_imp->environment->preferred_root_key()->value()))]->empty())
local_show = true;
show &= local_show;
diff --git a/paludis/repositories/e/ebuild_flat_metadata_cache_TEST.cc b/paludis/repositories/e/ebuild_flat_metadata_cache_TEST.cc
index 8dd8ab614..7005da784 100644
--- a/paludis/repositories/e/ebuild_flat_metadata_cache_TEST.cc
+++ b/paludis/repositories/e/ebuild_flat_metadata_cache_TEST.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2006, 2007, 2008, 2009, 2010 Ciaran McCreesh
+ * Copyright (c) 2006, 2007, 2008, 2009, 2010, 2011 Ciaran McCreesh
* Copyright (c) 2008 David Leverton
*
* This file is part of the Paludis package manager. Paludis is free software;
@@ -34,6 +34,7 @@
#include <paludis/util/safe_ifstream.hh>
#include <paludis/util/timestamp.hh>
#include <paludis/util/fs_stat.hh>
+#include <paludis/util/make_null_shared_ptr.hh>
#include <test/test_framework.hh>
#include <test/test_runner.hh>
#include <iterator>
@@ -77,7 +78,7 @@ namespace test_cases
std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_list-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id->short_description_key()));
TEST_CHECK_EQUAL(id->short_description_key()->value(), "the-description-flat_list");
@@ -105,7 +106,7 @@ namespace test_cases
const std::shared_ptr<const PackageID> id1(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_list-stale-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id1->short_description_key()));
TEST_CHECK_EQUAL(id1->short_description_key()->value(), "The Generated Description flat_list-stale");
@@ -134,7 +135,7 @@ namespace test_cases
const std::shared_ptr<const PackageID> id1(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_list-guessed-eapi-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id1->short_description_key()));
TEST_CHECK_EQUAL(id1->short_description_key()->value(), "The Generated Description flat_list-guessed-eapi");
@@ -162,7 +163,7 @@ namespace test_cases
std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_list-eclass-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id->short_description_key()));
TEST_CHECK_EQUAL(id->short_description_key()->value(), "the-description-flat_list-eclass");
@@ -193,7 +194,7 @@ namespace test_cases
const std::shared_ptr<const PackageID> id1(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_list-eclass-stale-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id1->short_description_key()));
TEST_CHECK_EQUAL(id1->short_description_key()->value(), "The Generated Description flat_list-eclass-stale");
@@ -221,7 +222,7 @@ namespace test_cases
const std::shared_ptr<const PackageID> id1(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_list-eclass-wrong-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id1->short_description_key()));
TEST_CHECK_EQUAL(id1->short_description_key()->value(), "The Generated Description flat_list-eclass-wrong");
@@ -249,7 +250,7 @@ namespace test_cases
const std::shared_ptr<const PackageID> id1(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_list-eclass-gone-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id1->short_description_key()));
TEST_CHECK_EQUAL(id1->short_description_key()->value(), "The Generated Description flat_list-eclass-gone");
@@ -277,7 +278,7 @@ namespace test_cases
std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_list-detection-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id->short_description_key()));
TEST_CHECK_EQUAL(id->short_description_key()->value(), "the-description-flat_list-detection");
@@ -305,7 +306,7 @@ namespace test_cases
std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_hash-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id->short_description_key()));
TEST_CHECK_EQUAL(id->short_description_key()->value(), "the-description-flat_hash");
@@ -334,7 +335,7 @@ namespace test_cases
const std::shared_ptr<const PackageID> id1(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_hash-guessed-eapi-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id1->short_description_key()));
TEST_CHECK_EQUAL(id1->short_description_key()->value(), "The Generated Description flat_hash-guessed-eapi");
@@ -362,7 +363,7 @@ namespace test_cases
const std::shared_ptr<const PackageID> id1(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_hash-guessed-eapi-extension-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id1->short_description_key()));
TEST_CHECK_EQUAL(id1->short_description_key()->value(), "The Generated Description flat_hash-guessed-eapi-extension");
@@ -390,7 +391,7 @@ namespace test_cases
std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_hash-no-guessed-eapi-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id->short_description_key()));
TEST_CHECK_EQUAL(id->short_description_key()->value(), "the-description-flat_hash-no-guessed-eapi");
@@ -418,7 +419,7 @@ namespace test_cases
std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_hash-empty-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id->short_description_key()));
TEST_CHECK_EQUAL(id->short_description_key()->value(), "");
@@ -447,7 +448,7 @@ namespace test_cases
const std::shared_ptr<const PackageID> id1(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_hash-stale-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id1->short_description_key()));
TEST_CHECK_EQUAL(id1->short_description_key()->value(), "The Generated Description flat_hash-stale");
@@ -475,7 +476,7 @@ namespace test_cases
const std::shared_ptr<const PackageID> id1(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_hash-no-mtime-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id1->short_description_key()));
TEST_CHECK_EQUAL(id1->short_description_key()->value(), "the-description-flat_hash-no-mtime");
@@ -503,7 +504,7 @@ namespace test_cases
const std::shared_ptr<const PackageID> id1(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_hash-no-mtime-stale-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id1->short_description_key()));
TEST_CHECK_EQUAL(id1->short_description_key()->value(), "The Generated Description flat_hash-no-mtime-stale");
@@ -531,7 +532,7 @@ namespace test_cases
const std::shared_ptr<const PackageID> id1(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_hash-bad-mtime-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id1->short_description_key()));
TEST_CHECK_EQUAL(id1->short_description_key()->value(), "The Generated Description flat_hash-bad-mtime");
@@ -559,7 +560,7 @@ namespace test_cases
const std::shared_ptr<const PackageID> id1(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_hash-no-eapi-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id1->short_description_key()));
TEST_CHECK_EQUAL(id1->short_description_key()->value(), "The Generated Description flat_hash-no-eapi");
@@ -587,7 +588,7 @@ namespace test_cases
const std::shared_ptr<const PackageID> id1(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_hash-duplicate-key-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id1->short_description_key()));
TEST_CHECK_EQUAL(id1->short_description_key()->value(), "The Generated Description flat_hash-duplicate-key");
@@ -615,7 +616,7 @@ namespace test_cases
std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_hash-eclass-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id->short_description_key()));
TEST_CHECK_EQUAL(id->short_description_key()->value(), "the-description-flat_hash-eclass");
@@ -646,7 +647,7 @@ namespace test_cases
std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_hash-eclass-stale-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id->short_description_key()));
TEST_CHECK_EQUAL(id->short_description_key()->value(), "The Generated Description flat_hash-eclass-stale");
@@ -674,7 +675,7 @@ namespace test_cases
std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_hash-eclass-wrong-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id->short_description_key()));
TEST_CHECK_EQUAL(id->short_description_key()->value(), "The Generated Description flat_hash-eclass-wrong");
@@ -701,7 +702,7 @@ namespace test_cases
std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_hash-eclass-gone-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id->short_description_key()));
TEST_CHECK_EQUAL(id->short_description_key()->value(), "The Generated Description flat_hash-eclass-gone");
@@ -729,7 +730,7 @@ namespace test_cases
std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_hash-full-eclass-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id->short_description_key()));
TEST_CHECK_EQUAL(id->short_description_key()->value(), "the-description-flat_hash-full-eclass");
@@ -760,7 +761,7 @@ namespace test_cases
std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_hash-full-eclass-nonstandard-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id->short_description_key()));
TEST_CHECK_EQUAL(id->short_description_key()->value(), "the-description-flat_hash-full-eclass-nonstandard");
@@ -791,7 +792,7 @@ namespace test_cases
std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_hash-full-eclass-stale-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id->short_description_key()));
TEST_CHECK_EQUAL(id->short_description_key()->value(), "The Generated Description flat_hash-full-eclass-stale");
@@ -819,7 +820,7 @@ namespace test_cases
std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_hash-full-eclass-wrong-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id->short_description_key()));
TEST_CHECK_EQUAL(id->short_description_key()->value(), "The Generated Description flat_hash-full-eclass-wrong");
@@ -847,7 +848,7 @@ namespace test_cases
std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_hash-full-eclass-gone-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id->short_description_key()));
TEST_CHECK_EQUAL(id->short_description_key()->value(), "The Generated Description flat_hash-full-eclass-gone");
@@ -875,14 +876,14 @@ namespace test_cases
std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_hash-eclasses-truncated-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id->short_description_key()));
TEST_CHECK_EQUAL(id->short_description_key()->value(), "The Generated Description flat_hash-eclasses-truncated");
std::shared_ptr<const PackageID> id2(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_hash-eclasses-truncated-2",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id2->short_description_key()));
TEST_CHECK_EQUAL(id2->short_description_key()->value(), "The Generated Description flat_hash-eclasses-truncated-2");
@@ -910,7 +911,7 @@ namespace test_cases
std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_hash-eclasses-bad-mtime-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id->short_description_key()));
TEST_CHECK_EQUAL(id->short_description_key()->value(), "The Generated Description flat_hash-eclasses-bad-mtime");
@@ -938,7 +939,7 @@ namespace test_cases
std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_hash-eclasses-spaces-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id->short_description_key()));
TEST_CHECK_EQUAL(id->short_description_key()->value(), "The Generated Description flat_hash-eclasses-spaces");
@@ -967,7 +968,7 @@ namespace test_cases
std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_hash-exlib-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id->short_description_key()));
TEST_CHECK_EQUAL(id->short_description_key()->value(), "the-description-flat_hash-exlib");
@@ -999,7 +1000,7 @@ namespace test_cases
std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_hash-exlib-percat-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id->short_description_key()));
TEST_CHECK_EQUAL(id->short_description_key()->value(), "the-description-flat_hash-exlib-percat");
@@ -1031,7 +1032,7 @@ namespace test_cases
std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_hash-exlib-stale-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id->short_description_key()));
TEST_CHECK_EQUAL(id->short_description_key()->value(), "The Generated Description flat_hash-exlib-stale");
@@ -1060,7 +1061,7 @@ namespace test_cases
std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_hash-exlib-wrong-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id->short_description_key()));
TEST_CHECK_EQUAL(id->short_description_key()->value(), "The Generated Description flat_hash-exlib-wrong");
@@ -1089,7 +1090,7 @@ namespace test_cases
std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_hash-exlib-gone-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id->short_description_key()));
TEST_CHECK_EQUAL(id->short_description_key()->value(), "The Generated Description flat_hash-exlib-gone");
@@ -1118,14 +1119,14 @@ namespace test_cases
std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_hash-exlibs-truncated-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id->short_description_key()));
TEST_CHECK_EQUAL(id->short_description_key()->value(), "The Generated Description flat_hash-exlibs-truncated");
std::shared_ptr<const PackageID> id2(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_hash-exlibs-truncated-2",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id2->short_description_key()));
TEST_CHECK_EQUAL(id2->short_description_key()->value(), "The Generated Description flat_hash-exlibs-truncated-2");
@@ -1154,7 +1155,7 @@ namespace test_cases
std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_hash-exlibs-bad-mtime-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id->short_description_key()));
TEST_CHECK_EQUAL(id->short_description_key()->value(), "The Generated Description flat_hash-exlibs-bad-mtime");
@@ -1183,7 +1184,7 @@ namespace test_cases
std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/flat_hash-exlibs-spaces-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id->short_description_key()));
TEST_CHECK_EQUAL(id->short_description_key()->value(), "The Generated Description flat_hash-exlibs-spaces");
@@ -1218,7 +1219,7 @@ namespace test_cases
std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/write-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id->short_description_key()));
TEST_CHECK_EQUAL(contents("ebuild_flat_metadata_cache_TEST_dir/cache/test-repo/cat/write-1"), contents("ebuild_flat_metadata_cache_TEST_dir/cache/expected/cat/write-1"));
@@ -1254,7 +1255,7 @@ namespace test_cases
std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/write-eapi1-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id->short_description_key()));
TEST_CHECK_EQUAL(contents("ebuild_flat_metadata_cache_TEST_dir/cache/test-repo/cat/write-eapi1-1"), contents("ebuild_flat_metadata_cache_TEST_dir/cache/expected/cat/write-eapi1-1"));
@@ -1292,7 +1293,7 @@ namespace test_cases
std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/write-eclasses-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id->short_description_key()));
TEST_CHECK_EQUAL(contents("ebuild_flat_metadata_cache_TEST_dir/cache/test-repo/cat/write-eclasses-1"), contents("ebuild_flat_metadata_cache_TEST_dir/cache/expected/cat/write-eclasses-1"));
@@ -1329,7 +1330,7 @@ namespace test_cases
std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/write-exlibs-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id->short_description_key()));
TEST_CHECK_EQUAL(contents("ebuild_flat_metadata_cache_TEST_dir/cache/test-repo/cat/write-exlibs-1"), contents("ebuild_flat_metadata_cache_TEST_dir/cache/expected/cat/write-exlibs-1"));
diff --git a/paludis/repositories/e/exheres_profile.cc b/paludis/repositories/e/exheres_profile.cc
index 9020e62e5..beae1cc51 100644
--- a/paludis/repositories/e/exheres_profile.cc
+++ b/paludis/repositories/e/exheres_profile.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2005, 2006, 2007, 2008, 2009, 2010 Ciaran McCreesh
+ * Copyright (c) 2005, 2006, 2007, 2008, 2009, 2010, 2011 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -367,7 +367,7 @@ ExheresProfile::profile_masked(const std::shared_ptr<const PackageID> & id) cons
{
for (std::list<std::pair<std::shared_ptr<const PackageDepSpec>, std::shared_ptr<const RepositoryMaskInfo> > >::const_iterator k(rr->second.begin()),
k_end(rr->second.end()) ; k != k_end ; ++k)
- if (match_package(*_imp->env, *k->first, id, { }))
+ if (match_package(*_imp->env, *k->first, id, make_null_shared_ptr(), { }))
return k->second;
}
diff --git a/paludis/repositories/e/exndbam_repository_TEST.cc b/paludis/repositories/e/exndbam_repository_TEST.cc
index ed804688a..c48ff4d27 100644
--- a/paludis/repositories/e/exndbam_repository_TEST.cc
+++ b/paludis/repositories/e/exndbam_repository_TEST.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2008, 2009, 2010 Ciaran McCreesh
+ * Copyright (c) 2008, 2009, 2010, 2011 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -26,6 +26,7 @@
#include <paludis/util/make_named_values.hh>
#include <paludis/util/sequence.hh>
#include <paludis/util/fs_path.hh>
+#include <paludis/util/make_null_shared_ptr.hh>
#include <paludis/standard_output_manager.hh>
#include <paludis/action.hh>
#include <paludis/filtered_generator.hh>
@@ -109,7 +110,7 @@ namespace test_cases
if (! victim.empty())
replacing->push_back(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec(victim,
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
InstallAction install_action(make_named_values<InstallActionOptions>(
n::destination() = exndbam_repo,
n::make_output_manager() = &make_standard_output_manager,
@@ -119,7 +120,7 @@ namespace test_cases
));
(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec(chosen_one,
- &env, { })), { }))]->begin())->perform_action(install_action);
+ &env, { })), make_null_shared_ptr(), { }))]->begin())->perform_action(install_action);
}
void run()
diff --git a/paludis/repositories/e/fetch_visitor_TEST.cc b/paludis/repositories/e/fetch_visitor_TEST.cc
index 4c9d523f7..cc3d7f33a 100644
--- a/paludis/repositories/e/fetch_visitor_TEST.cc
+++ b/paludis/repositories/e/fetch_visitor_TEST.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2007, 2008, 2009, 2010 Ciaran McCreesh
+ * Copyright (c) 2007, 2008, 2009, 2010, 2011 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -26,6 +26,7 @@
#include <paludis/util/sequence.hh>
#include <paludis/util/make_named_values.hh>
#include <paludis/util/fs_stat.hh>
+#include <paludis/util/make_null_shared_ptr.hh>
#include <paludis/standard_output_manager.hh>
#include <paludis/util/safe_ifstream.hh>
#include <paludis/package_database.hh>
@@ -78,7 +79,7 @@ namespace test_cases
const std::shared_ptr<const EAPI> eapi(EAPIData::get_instance()->eapi_from_string("exheres-0"));
FetchVisitor v(&env, *env[selection::RequireExactlyOne(
generator::Matches(parse_user_package_dep_spec("=cat/pkg-1",
- &env, { }), { }))]->begin(),
+ &env, { }), make_null_shared_ptr(), { }))]->begin(),
*eapi, FSPath("fetch_visitor_TEST_dir/out"),
false, false, "test", std::make_shared<URIListedThenMirrorsLabel>("listed-then-mirrors"), false,
std::make_shared<StandardOutputManager>(), get_mirrors_fn);
diff --git a/paludis/repositories/e/fix_locked_dependencies.cc b/paludis/repositories/e/fix_locked_dependencies.cc
index e6dc55358..a17a5d51a 100644
--- a/paludis/repositories/e/fix_locked_dependencies.cc
+++ b/paludis/repositories/e/fix_locked_dependencies.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2008, 2009, 2010 Ciaran McCreesh
+ * Copyright (c) 2008, 2009, 2010, 2011 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -108,7 +108,7 @@ namespace
break;
std::shared_ptr<const PackageIDSequence> matches((*env)[selection::AllVersionsSorted(
- generator::Matches(*node.spec(), { }) | filter::InstalledAtRoot(env->system_root_key()->value()))]);
+ generator::Matches(*node.spec(), id, { }) | filter::InstalledAtRoot(env->system_root_key()->value()))]);
if (matches->empty())
break;
diff --git a/paludis/repositories/e/info_metadata_key.cc b/paludis/repositories/e/info_metadata_key.cc
index a14cfbd78..ec16cb699 100644
--- a/paludis/repositories/e/info_metadata_key.cc
+++ b/paludis/repositories/e/info_metadata_key.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2008, 2009, 2010 Ciaran McCreesh
+ * Copyright (c) 2008, 2009, 2010, 2011 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -32,6 +32,7 @@
#include <paludis/util/indirect_iterator-impl.hh>
#include <paludis/util/join.hh>
#include <paludis/util/fs_stat.hh>
+#include <paludis/util/make_null_shared_ptr.hh>
#include <paludis/literal_metadata_key.hh>
#include <paludis/selection.hh>
@@ -189,7 +190,7 @@ InfoPkgsMetadataKey::need_keys_added() const
generator::Matches(parse_elike_package_dep_spec(i->first,
eapi->supported()->package_dep_spec_parse_options(),
eapi->supported()->version_spec_options(),
- std::shared_ptr<const PackageID>()), { }) |
+ std::shared_ptr<const PackageID>()), make_null_shared_ptr(), { }) |
filter::InstalledAtRoot(_imp->env->preferred_root_key()->value()))]);
if (q->empty())
diff --git a/paludis/repositories/e/pipe_command_handler.cc b/paludis/repositories/e/pipe_command_handler.cc
index 0e839ebec..46e9bc8a9 100644
--- a/paludis/repositories/e/pipe_command_handler.cc
+++ b/paludis/repositories/e/pipe_command_handler.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2007, 2008, 2009, 2010 Ciaran McCreesh
+ * Copyright (c) 2007, 2008, 2009, 2010, 2011 Ciaran McCreesh
* Copyright (c) 2009 Ingmar Vanhassel
*
* This file is part of the Paludis package manager. Paludis is free software;
@@ -277,7 +277,7 @@ paludis::erepository::pipe_command_handler(const Environment * const environment
eapi->supported()->package_dep_spec_parse_options(),
eapi->supported()->version_spec_options(), package_id));
std::shared_ptr<const PackageIDSequence> entries((*environment)[selection::AllVersionsSorted(
- generator::Matches(spec, { }) | root)]);
+ generator::Matches(spec, package_id, { }) | root)]);
if (eapi->supported()->pipe_commands()->rewrite_virtuals() && (! entries->empty()) &&
(*entries->last())->virtual_for_key())
{
@@ -326,7 +326,7 @@ paludis::erepository::pipe_command_handler(const Environment * const environment
eapi->supported()->package_dep_spec_parse_options(),
eapi->supported()->version_spec_options(), package_id));
std::shared_ptr<const PackageIDSequence> entries((*environment)[selection::SomeArbitraryVersion(
- generator::Matches(spec, { }) | root)]);
+ generator::Matches(spec, package_id, { }) | root)]);
if (entries->empty())
return "O1;";
else
@@ -350,7 +350,7 @@ paludis::erepository::pipe_command_handler(const Environment * const environment
eapi->supported()->package_dep_spec_parse_options(),
eapi->supported()->version_spec_options(), package_id));
std::shared_ptr<const PackageIDSequence> entries((*environment)[selection::AllVersionsSorted(
- generator::Matches(spec, { }) | filter::InstalledAtRoot(environment->preferred_root_key()->value()))]);
+ generator::Matches(spec, package_id, { }) | filter::InstalledAtRoot(environment->preferred_root_key()->value()))]);
if (eapi->supported()->pipe_commands()->rewrite_virtuals() && (! entries->empty()))
{
std::shared_ptr<PackageIDSequence> new_entries(std::make_shared<PackageIDSequence>());
diff --git a/paludis/repositories/e/traditional_profile.cc b/paludis/repositories/e/traditional_profile.cc
index ce8cee8d9..94aecd78c 100644
--- a/paludis/repositories/e/traditional_profile.cc
+++ b/paludis/repositories/e/traditional_profile.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2005, 2006, 2007, 2008, 2009, 2010 Ciaran McCreesh
+ * Copyright (c) 2005, 2006, 2007, 2008, 2009, 2010, 2011 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -43,6 +43,7 @@
#include <paludis/util/map.hh>
#include <paludis/util/fs_stat.hh>
#include <paludis/util/fs_error.hh>
+#include <paludis/util/make_null_shared_ptr.hh>
#include <paludis/choice.hh>
#include <paludis/dep_tag.hh>
@@ -872,7 +873,7 @@ TraditionalProfile::use_masked(
for (PackageFlagStatusMapList::const_iterator g(i->package_use_mask.begin()),
g_end(i->package_use_mask.end()) ; g != g_end ; ++g)
{
- if (! match_package(*_imp->env, *g->first, id, { }))
+ if (! match_package(*_imp->env, *g->first, id, make_null_shared_ptr(), { }))
continue;
FlagStatusMap::const_iterator h(g->second.find(value_prefixed));
@@ -908,7 +909,7 @@ TraditionalProfile::use_forced(
for (PackageFlagStatusMapList::const_iterator g(i->package_use_force.begin()),
g_end(i->package_use_force.end()) ; g != g_end ; ++g)
{
- if (! match_package(*_imp->env, *g->first, id, { }))
+ if (! match_package(*_imp->env, *g->first, id, make_null_shared_ptr(), { }))
continue;
FlagStatusMap::const_iterator h(g->second.find(value_prefixed));
@@ -937,7 +938,7 @@ TraditionalProfile::use_state_ignoring_masks(
for (PackageFlagStatusMapList::const_iterator g(i->package_use.begin()),
g_end(i->package_use.end()) ; g != g_end ; ++g)
{
- if (! match_package(*_imp->env, *g->first, id, { }))
+ if (! match_package(*_imp->env, *g->first, id, make_null_shared_ptr(), { }))
continue;
FlagStatusMap::const_iterator h(g->second.find(value_prefixed));
@@ -1046,7 +1047,7 @@ TraditionalProfile::profile_masked(const std::shared_ptr<const PackageID> & id)
{
for (std::list<std::pair<std::shared_ptr<const PackageDepSpec>, std::shared_ptr<const RepositoryMaskInfo> > >::const_iterator k(rr->second.begin()),
k_end(rr->second.end()) ; k != k_end ; ++k)
- if (match_package(*_imp->env, *k->first, id, { }))
+ if (match_package(*_imp->env, *k->first, id, make_null_shared_ptr(), { }))
return k->second;
}
diff --git a/paludis/repositories/e/vdb_repository.cc b/paludis/repositories/e/vdb_repository.cc
index f4901e86a..3318279ef 100644
--- a/paludis/repositories/e/vdb_repository.cc
+++ b/paludis/repositories/e/vdb_repository.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2006, 2007, 2008, 2009, 2010 Ciaran McCreesh
+ * Copyright (c) 2006, 2007, 2008, 2009, 2010, 2011 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -1443,7 +1443,7 @@ VDBRepository::perform_updates()
SlotName old_slot(tokens.at(2)), new_slot(tokens.at(3));
const std::shared_ptr<const PackageIDSequence> ids((*_imp->params.environment())[selection::AllVersionsSorted(
- (generator::Matches(old_spec, { }) & generator::InRepository(name())) |
+ (generator::Matches(old_spec, make_null_shared_ptr(), { }) & generator::InRepository(name())) |
filter::Slot(old_slot)
)]);
if (! ids->empty())
diff --git a/paludis/repositories/e/vdb_repository_TEST.cc b/paludis/repositories/e/vdb_repository_TEST.cc
index a0205b5ec..e28ba6f31 100644
--- a/paludis/repositories/e/vdb_repository_TEST.cc
+++ b/paludis/repositories/e/vdb_repository_TEST.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2006, 2007, 2008, 2009, 2010 Ciaran McCreesh
+ * Copyright (c) 2006, 2007, 2008, 2009, 2010, 2011 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -153,7 +153,7 @@ namespace test_cases
std::shared_ptr<const PackageID> e1(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat-one/pkg-one-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(e1->choices_key()));
TEST_CHECK(bool(e1->choices_key()->value()));
@@ -224,7 +224,7 @@ namespace test_cases
std::shared_ptr<const PackageID> e1(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat-one/pkg-one-1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
ContentsGatherer gatherer;
std::for_each(indirect_iterator(e1->contents_key()->value()->begin()),
indirect_iterator(e1->contents_key()->value()->end()),
@@ -278,7 +278,7 @@ namespace test_cases
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("category/package",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
UnformattedPrettyPrinter ff;
@@ -381,7 +381,7 @@ namespace test_cases
TestMessageSuffix suffix("install", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/target-" + eapi + "::srcrepo",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id));
id->perform_action(install_action);
}
@@ -392,7 +392,7 @@ namespace test_cases
TestMessageSuffix suffix("reinstall", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/target-" + eapi + "::srcrepo",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id));
id->perform_action(install_action);
}
@@ -403,7 +403,7 @@ namespace test_cases
TestMessageSuffix suffix("info", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/target-" + eapi + "::installed",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id));
id->perform_action(info_action);
}
@@ -412,7 +412,7 @@ namespace test_cases
TestMessageSuffix suffix("config", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/target-" + eapi + "::installed",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id));
id->perform_action(config_action);
}
@@ -421,7 +421,7 @@ namespace test_cases
TestMessageSuffix suffix("uninstall", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/target-" + eapi + "::installed",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id));
id->perform_action(uninstall_action);
}
@@ -511,7 +511,7 @@ namespace test_cases
TestMessageSuffix suffix("vars", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/target-" + eapi + "::srcrepo",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id));
id->perform_action(install_action);
}
@@ -522,7 +522,7 @@ namespace test_cases
TestMessageSuffix suffix("reinstall", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/target-" + eapi + "::srcrepo",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id));
id->perform_action(install_action);
}
@@ -533,7 +533,7 @@ namespace test_cases
TestMessageSuffix suffix("info", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/target-" + eapi + "::installed",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id));
id->perform_action(info_action);
}
@@ -542,7 +542,7 @@ namespace test_cases
TestMessageSuffix suffix("config", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/target-" + eapi + "::installed",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id));
id->perform_action(config_action);
}
@@ -551,7 +551,7 @@ namespace test_cases
TestMessageSuffix suffix("uninstall", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/target-" + eapi + "::installed",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(bool(id));
id->perform_action(uninstall_action);
}
@@ -588,7 +588,7 @@ namespace test_cases
if (! victim.empty())
replacing->push_back(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec(victim,
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
InstallAction install_action(make_named_values<InstallActionOptions>(
n::destination() = vdb_repo,
n::make_output_manager() = &make_standard_output_manager,
@@ -598,7 +598,7 @@ namespace test_cases
));
(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec(chosen_one,
- &env, { })), { }))]->begin())->perform_action(install_action);
+ &env, { })), make_null_shared_ptr(), { }))]->begin())->perform_action(install_action);
}
void run()
@@ -710,7 +710,7 @@ namespace test_cases
TestMessageSuffix suffix("remove other slot", true);
const std::shared_ptr<const PackageID> inst_id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat1/pkg1-2::installed",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
inst_id->perform_action(uninstall_action);
vdb_repo->invalidate();
@@ -739,7 +739,7 @@ namespace test_cases
TestMessageSuffix suffix("remove other package", true);
const std::shared_ptr<const PackageID> inst_id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat1/pkg2-1::installed",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
inst_id->perform_action(uninstall_action);
vdb_repo->invalidate();
@@ -766,7 +766,7 @@ namespace test_cases
TestMessageSuffix suffix("remove other category", true);
const std::shared_ptr<const PackageID> inst_id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat2/pkg1-1::installed",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
inst_id->perform_action(uninstall_action);
vdb_repo->invalidate();
@@ -781,7 +781,7 @@ namespace test_cases
TestMessageSuffix suffix("uninstall", true);
const std::shared_ptr<const PackageID> inst_id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat1/pkg1-1::installed",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
inst_id->perform_action(uninstall_action);
vdb_repo->invalidate();
@@ -955,7 +955,7 @@ namespace test_cases
if (! victim.empty())
replacing->push_back(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec(victim,
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
InstallAction install_action(make_named_values<InstallActionOptions>(
n::destination() = vdb_repo,
n::make_output_manager() = &make_standard_output_manager,
@@ -965,7 +965,7 @@ namespace test_cases
));
(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec(chosen_one,
- &env, { })), { }))]->begin())->perform_action(install_action);
+ &env, { })), make_null_shared_ptr(), { }))]->begin())->perform_action(install_action);
}
void run()
@@ -1085,7 +1085,7 @@ namespace test_cases
TestMessageSuffix suffix("remove other slot", true);
const std::shared_ptr<const PackageID> inst_id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat1/pkg1-2::installed",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
inst_id->perform_action(uninstall_action);
vdb_repo->invalidate();
@@ -1104,7 +1104,7 @@ namespace test_cases
TestMessageSuffix suffix("remove other package", true);
const std::shared_ptr<const PackageID> inst_id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat1/pkg2-1::installed",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
inst_id->perform_action(uninstall_action);
vdb_repo->invalidate();
@@ -1115,7 +1115,7 @@ namespace test_cases
TestMessageSuffix suffix("uninstall", true);
const std::shared_ptr<const PackageID> inst_id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat1/pkg1-1::installed",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
inst_id->perform_action(uninstall_action);
vdb_repo->invalidate();
@@ -1224,7 +1224,7 @@ namespace test_cases
TestMessageSuffix suffix("install", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/pkg-1::reinstalltest_src1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
id->perform_action(install_action);
vdb_repo->invalidate();
@@ -1236,7 +1236,7 @@ namespace test_cases
TestMessageSuffix suffix("reinstall", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/pkg-1::reinstalltest_src1",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
id->perform_action(install_action);
vdb_repo->invalidate();
@@ -1248,7 +1248,7 @@ namespace test_cases
TestMessageSuffix suffix("reinstall equivalent", true);
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec("=cat/pkg-1::reinstalltest_src2",
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
id->perform_action(install_action);
vdb_repo->invalidate();
@@ -1281,7 +1281,7 @@ namespace test_cases
if (! victim.empty())
replacing->push_back(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec(victim,
- &env, { })), { }))]->begin());
+ &env, { })), make_null_shared_ptr(), { }))]->begin());
InstallAction install_action(make_named_values<InstallActionOptions>(
n::destination() = vdb_repo,
n::make_output_manager() = &make_standard_output_manager,
@@ -1291,7 +1291,7 @@ namespace test_cases
));
(*env[selection::RequireExactlyOne(generator::Matches(
PackageDepSpec(parse_user_package_dep_spec(chosen_one,
- &env, { })), { }))]->begin())->perform_action(install_action);
+ &env, { })), make_null_shared_ptr(), { }))]->begin())->perform_action(install_action);
}
void run()
diff --git a/paludis/repositories/e/vdb_unmerger_TEST.cc b/paludis/repositories/e/vdb_unmerger_TEST.cc
index 5610f3dbb..c7e96c543 100644
--- a/paludis/repositories/e/vdb_unmerger_TEST.cc
+++ b/paludis/repositories/e/vdb_unmerger_TEST.cc
@@ -26,6 +26,7 @@
#include <paludis/util/wrapped_forward_iterator.hh>
#include <paludis/util/sequence.hh>
#include <paludis/util/fs_stat.hh>
+#include <paludis/util/make_null_shared_ptr.hh>
#include <paludis/standard_output_manager.hh>
#include <paludis/user_dep_spec.hh>
#include <paludis/package_database.hh>
@@ -129,8 +130,7 @@ namespace
n::ignore() = &ignore_nothing,
n::output_manager() = std::make_shared<StandardOutputManager>(),
n::package_id() = *env[selection::RequireExactlyOne(generator::Matches(
- parse_user_package_dep_spec("cat/" + fix(what), &env, { }),
- { }))]->begin(),
+ parse_user_package_dep_spec("cat/" + fix(what), &env, { }), make_null_shared_ptr(), { }))]->begin(),
n::root() = root_dir
));
diff --git a/paludis/repositories/unpackaged/installed_repository_TEST.cc b/paludis/repositories/unpackaged/installed_repository_TEST.cc
index cd83a654b..ff554986f 100644
--- a/paludis/repositories/unpackaged/installed_repository_TEST.cc
+++ b/paludis/repositories/unpackaged/installed_repository_TEST.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2007, 2008, 2009, 2010 Ciaran McCreesh
+ * Copyright (c) 2007, 2008, 2009, 2010, 2011 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -138,7 +138,7 @@ namespace test_cases
const std::shared_ptr<const PackageID> id1(*env[selection::RequireExactlyOne(
generator::Matches(parse_user_package_dep_spec("cat-one/foo:0",
- &env, { }), { }))]->begin());
+ &env, { }), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK_EQUAL(id1->version(), VersionSpec("1", { }));
TEST_CHECK_EQUAL(id1->slot_key()->value(), SlotName("0"));
@@ -156,7 +156,7 @@ namespace test_cases
const std::shared_ptr<const PackageID> id2(*env[selection::RequireExactlyOne(
generator::Matches(parse_user_package_dep_spec("cat-one/foo:1",
- &env, { }), { }))]->begin());
+ &env, { }), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK_EQUAL(id2->version(), VersionSpec("2", { }));
TEST_CHECK_EQUAL(id2->slot_key()->value(), SlotName("1"));
@@ -192,13 +192,13 @@ namespace test_cases
const std::shared_ptr<const PackageID> id1(*env[selection::RequireExactlyOne(
generator::Matches(parse_user_package_dep_spec("cat-one/foo:0",
- &env, { }), { }))]->begin());
+ &env, { }), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(! id1->masked());
const std::shared_ptr<const PackageID> id2(*env[selection::RequireExactlyOne(
generator::Matches(parse_user_package_dep_spec("cat-one/foo:1",
- &env, { }), { }))]->begin());
+ &env, { }), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(! id2->masked());
}
@@ -228,7 +228,7 @@ namespace test_cases
const std::shared_ptr<const PackageID> id1(*env[selection::RequireExactlyOne(
generator::Matches(parse_user_package_dep_spec("cat-one/foo:1",
- &env, { }), { }))]->begin());
+ &env, { }), make_null_shared_ptr(), { }))]->begin());
TEST_CHECK(! id1->supports_action(SupportsActionTest<InstallAction>()));
TEST_CHECK(! id1->supports_action(SupportsActionTest<ConfigAction>()));
@@ -320,7 +320,7 @@ namespace test_cases
const std::shared_ptr<const PackageID> id(*env[selection::RequireExactlyOne(
generator::Matches(parse_user_package_dep_spec("cat-one/foo:fred",
- &env, { }), { }))]->begin());
+ &env, { }), make_null_shared_ptr(), { }))]->begin());
UninstallAction action(make_named_values<UninstallActionOptions>(
n::config_protect() = "",
@@ -585,7 +585,7 @@ namespace test_cases
));
(*env[selection::RequireExactlyOne(generator::Matches(
parse_user_package_dep_spec("cat/pkg4a",
- &env, { }), { }))]->begin())->perform_action(action);
+ &env, { }), make_null_shared_ptr(), { }))]->begin())->perform_action(action);
TEST_CHECK(FSPath("installed_repository_TEST_dir/root4/dir").stat().is_directory());
TEST_CHECK(! FSPath("installed_repository_TEST_dir/root4/dir/4a").stat().is_regular_file());
@@ -631,7 +631,7 @@ namespace test_cases
));
(*env[selection::RequireExactlyOne(generator::Matches(
parse_user_package_dep_spec("cat/pkg4b",
- &env, { }), { }))]->begin())->perform_action(action);
+ &env, { }), make_null_shared_ptr(), { }))]->begin())->perform_action(action);
TEST_CHECK(! FSPath("installed_repository_TEST_dir/root4/dir").stat().is_directory());
diff --git a/paludis/repositories/virtuals/virtuals_repository.cc b/paludis/repositories/virtuals/virtuals_repository.cc
index a17dce361..c1af193d1 100644
--- a/paludis/repositories/virtuals/virtuals_repository.cc
+++ b/paludis/repositories/virtuals/virtuals_repository.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2006, 2007, 2008, 2009, 2010 Ciaran McCreesh
+ * Copyright (c) 2006, 2007, 2008, 2009, 2010, 2011 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -223,7 +223,7 @@ VirtualsRepository::need_ids() const
v(_imp->names.begin()), v_end(_imp->names.end()) ; v != v_end ; ++v)
{
std::shared_ptr<const PackageIDSequence> matches((*_imp->env)[selection::AllVersionsSorted(
- generator::Matches(*v->second, { }) |
+ generator::Matches(*v->second, make_null_shared_ptr(), { }) |
filter::SupportsAction<InstallAction>())]);
if (matches->empty())