aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2008-07-15 22:05:16 +0100
committerAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2008-07-15 22:08:27 +0100
commit45f1ef9c3be6190933e42c22c61f37c019f16ca7 (patch)
treeca09c2510ed07bf9c25e78895a1abc1f10cd8ea1
parentea0cc80ee33c07b73e88d9b832fd1f5a08afa351 (diff)
downloadpaludis-45f1ef9c3be6190933e42c22c61f37c019f16ca7.tar.gz
paludis-45f1ef9c3be6190933e42c22c61f37c019f16ca7.tar.xz
Make DepSpecFlattener throw on duff sets.
Rather than warning, DepSpecFlattener now throws if given a recursive or non-existent set.
-rw-r--r--paludis/dep_spec_flattener.cc11
1 files changed, 3 insertions, 8 deletions
diff --git a/paludis/dep_spec_flattener.cc b/paludis/dep_spec_flattener.cc
index cea26c2..f40460c 100644
--- a/paludis/dep_spec_flattener.cc
+++ b/paludis/dep_spec_flattener.cc
@@ -21,6 +21,7 @@
#include <paludis/dep_spec.hh>
#include <paludis/dep_tree.hh>
#include <paludis/environment.hh>
+#include <paludis/repository.hh>
#include <paludis/util/visitor-impl.hh>
#include <paludis/util/private_implementation_pattern-impl.hh>
#include <paludis/util/log.hh>
@@ -125,16 +126,10 @@ dep_spec_flattener_internals::VisitNamedSetDepSpec<Heirarchy_, Item_, true>::vis
std::tr1::shared_ptr<const SetSpecTree::ConstItem> set(f->_imp->env->set(s.name()));
if (! set)
- {
- Log::get_instance()->message("flattener.unknown_set", ll_warning, lc_context) << "Unknown set '" << s.name() << "'";
- return;
- }
+ throw NoSuchSetError(stringify(s.name()));
if (! this->_imp->recursing_sets.insert(s.name()).second)
- {
- Log::get_instance()->message("flattener.recursive_set", ll_warning, lc_context) << "Recursively defined set '" << s.name() << "'";
- return;
- }
+ throw RecursivelyDefinedSetError(stringify(s.name()));
set->accept(*f);