diff --git a/opm/core/utility/MonotCubicInterpolator.cpp b/opm/core/utility/MonotCubicInterpolator.cpp index d6889e1a..1a469f12 100644 --- a/opm/core/utility/MonotCubicInterpolator.cpp +++ b/opm/core/utility/MonotCubicInterpolator.cpp @@ -166,7 +166,7 @@ read(const std::string & datafilename, int xColumn, int fColumn) void MonotCubicInterpolator:: -addPair(double newx, double newf) throw(const char*) { +addPair(double newx, double newf) { if (std::isnan(newx) || std::isinf(newx) || std::isnan(newf) || std::isinf(newf)) { throw("MonotCubicInterpolator: addPair() received inf/nan input."); } @@ -181,7 +181,7 @@ addPair(double newx, double newf) throw(const char*) { double MonotCubicInterpolator:: -evaluate(double x) const throw(const char*){ +evaluate(double x) const { if (std::isnan(x) || std::isinf(x)) { throw("MonotCubicInterpolator: evaluate() received inf/nan input."); @@ -303,7 +303,7 @@ toString() const pair MonotCubicInterpolator:: -getMissingX() const throw(const char*) +getMissingX() const { if( data.size() < 2) { throw("MonotCubicInterpolator::getMissingX() only one datapoint."); @@ -337,7 +337,7 @@ getMissingX() const throw(const char*) pair MonotCubicInterpolator:: -getMaximumF() const throw(const char*) { +getMaximumF() const { if (data.size() <= 1) { throw ("MonotCubicInterpolator::getMaximumF() empty data.") ; } @@ -360,7 +360,7 @@ getMaximumF() const throw(const char*) { pair MonotCubicInterpolator:: -getMinimumF() const throw(const char*) { +getMinimumF() const { if (data.size() <= 1) { throw ("MonotCubicInterpolator::getMinimumF() empty data.") ; } diff --git a/opm/core/utility/MonotCubicInterpolator.hpp b/opm/core/utility/MonotCubicInterpolator.hpp index 668b14fa..25cf3cd5 100644 --- a/opm/core/utility/MonotCubicInterpolator.hpp +++ b/opm/core/utility/MonotCubicInterpolator.hpp @@ -71,7 +71,7 @@ class MonotCubicInterpolator { Ignores all lines not conforming to \\\\\\ */ - MonotCubicInterpolator(const std::string & datafilename) throw (const char*) + MonotCubicInterpolator(const std::string & datafilename) { if (!read(datafilename)) { throw("Unable to constuct MonotCubicInterpolator from file.") ; @@ -92,7 +92,7 @@ class MonotCubicInterpolator { */ - MonotCubicInterpolator(const char* datafilename) throw (const char*) + MonotCubicInterpolator(const char* datafilename) { if (!read(std::string(datafilename))) { throw("Unable to constuct MonotCubicInterpolator from file.") ; @@ -108,7 +108,7 @@ class MonotCubicInterpolator { Accepts a filename as input, and parses the chosen columns in that file. */ - MonotCubicInterpolator(const char* datafilename, int xColumn, int fColumn) throw (const char*) + MonotCubicInterpolator(const char* datafilename, int xColumn, int fColumn) { if (!read(std::string(datafilename),xColumn,fColumn)) { throw("Unable to constuct MonotCubicInterpolator from file.") ; @@ -123,7 +123,7 @@ class MonotCubicInterpolator { Accepts a filename as input, and parses the chosen columns in that file. */ - MonotCubicInterpolator(const std::string & datafilename, int xColumn, int fColumn) throw (const char*) + MonotCubicInterpolator(const std::string & datafilename, int xColumn, int fColumn) { if (!read(datafilename,xColumn,fColumn)) { throw("Unable to constuct MonotCubicInterpolator from file.") ; @@ -204,7 +204,7 @@ class MonotCubicInterpolator { @return f(x) for a given x */ - double evaluate(double x) const throw(const char*); + double evaluate(double x) const; /** @param x x value @@ -255,7 +255,7 @@ class MonotCubicInterpolator { @return x value corresponding to maximum f value @return maximum f value */ - std::pair getMaximumF() const throw(const char*) ; + std::pair getMaximumF() const ; /** Minimum f-value, returns both x and f in a pair @@ -263,7 +263,7 @@ class MonotCubicInterpolator { @return x value corresponding to minimal f value @return minimum f value */ - std::pair getMinimumF() const throw(const char*) ; + std::pair getMinimumF() const ; /** @@ -407,7 +407,7 @@ class MonotCubicInterpolator { must be exploited. */ - void addPair(double newx, double newf) throw(const char*); + void addPair(double newx, double newf); /** Returns an x-value that is believed to yield the best @@ -421,7 +421,7 @@ class MonotCubicInterpolator { @return New x value beleived to yield the best improvement in global accuracy @return Maximal difference */ - std::pair getMissingX() const throw(const char*) ; + std::pair getMissingX() const; /** Constructs a string containing the data in a table