1.1 --- a/lemon/preflow.h Fri Nov 21 14:11:29 2008 +0000
1.2 +++ b/lemon/preflow.h Fri Nov 21 14:26:58 2008 +0000
1.3 @@ -19,7 +19,6 @@
1.4 #ifndef LEMON_PREFLOW_H
1.5 #define LEMON_PREFLOW_H
1.6
1.7 -#include <lemon/error.h>
1.8 #include <lemon/tolerance.h>
1.9 #include <lemon/elevator.h>
1.10
1.11 @@ -132,17 +131,6 @@
1.12 typedef typename Traits::Elevator Elevator;
1.13 typedef typename Traits::Tolerance Tolerance;
1.14
1.15 - /// \brief \ref Exception for uninitialized parameters.
1.16 - ///
1.17 - /// This error represents problems in the initialization
1.18 - /// of the parameters of the algorithms.
1.19 - class UninitializedParameter : public lemon::Exception {
1.20 - public:
1.21 - virtual const char* what() const throw() {
1.22 - return "lemon::Preflow::UninitializedParameter";
1.23 - }
1.24 - };
1.25 -
1.26 private:
1.27
1.28 TEMPLATE_DIGRAPH_TYPEDEFS(Digraph);
1.29 @@ -208,7 +196,8 @@
1.30 struct DefFlowMapTraits : public Traits {
1.31 typedef _FlowMap FlowMap;
1.32 static FlowMap *createFlowMap(const Digraph&) {
1.33 - throw UninitializedParameter();
1.34 + LEMON_ASSERT(false, "FlowMap is not initialized");
1.35 + return 0; // ignore warnings
1.36 }
1.37 };
1.38
1.39 @@ -228,7 +217,8 @@
1.40 struct DefElevatorTraits : public Traits {
1.41 typedef _Elevator Elevator;
1.42 static Elevator *createElevator(const Digraph&, int) {
1.43 - throw UninitializedParameter();
1.44 + LEMON_ASSERT(false, "Elevator is not initialized");
1.45 + return 0; // ignore warnings
1.46 }
1.47 };
1.48