diff -r f6899946c1ac -r d901321d6555 lemon/lgf_writer.h --- a/lemon/lgf_writer.h Tue Sep 30 20:53:18 2008 +0200 +++ b/lemon/lgf_writer.h Wed Oct 01 11:58:03 2008 +0200 @@ -463,7 +463,7 @@ DigraphWriter(const std::string& fn, const Digraph& digraph) : _os(new std::ofstream(fn.c_str())), local_os(true), _digraph(digraph), _skip_nodes(false), _skip_arcs(false) { - if (!(*_os)) throw IoError(fn, "Cannot write file"); + if (!(*_os)) throw IoError("Cannot write file", fn); } /// \brief Constructor @@ -473,7 +473,7 @@ DigraphWriter(const char* fn, const Digraph& digraph) : _os(new std::ofstream(fn)), local_os(true), _digraph(digraph), _skip_nodes(false), _skip_arcs(false) { - if (!(*_os)) throw IoError(fn, "Cannot write file"); + if (!(*_os)) throw IoError("Cannot write file", fn); } /// \brief Destructor @@ -1023,7 +1023,7 @@ GraphWriter(const std::string& fn, const Graph& graph) : _os(new std::ofstream(fn.c_str())), local_os(true), _graph(graph), _skip_nodes(false), _skip_edges(false) { - if (!(*_os)) throw IoError(fn, "Cannot write file"); + if (!(*_os)) throw IoError("Cannot write file", fn); } /// \brief Constructor @@ -1033,7 +1033,7 @@ GraphWriter(const char* fn, const Graph& graph) : _os(new std::ofstream(fn)), local_os(true), _graph(graph), _skip_nodes(false), _skip_edges(false) { - if (!(*_os)) throw IoError(fn, "Cannot write file"); + if (!(*_os)) throw IoError("Cannot write file", fn); } /// \brief Destructor @@ -1585,7 +1585,7 @@ /// Construct a section writer, which writes into the given file. SectionWriter(const std::string& fn) : _os(new std::ofstream(fn.c_str())), local_os(true) { - if (!(*_os)) throw IoError(fn, "Cannot write file"); + if (!(*_os)) throw IoError("Cannot write file", fn); } /// \brief Constructor @@ -1593,7 +1593,7 @@ /// Construct a section writer, which writes into the given file. SectionWriter(const char* fn) : _os(new std::ofstream(fn)), local_os(true) { - if (!(*_os)) throw IoError(fn, "Cannot write file"); + if (!(*_os)) throw IoError("Cannot write file", fn); } /// \brief Destructor