[libgdamm] Remove GLIBMM_EXCEPTIONS_ENABLED ifdefs.



commit 7e2d6a84eca12e7ac390cfe9688fc764e5042a72
Author: Murray Cumming <murrayc murrayc com>
Date:   Wed Mar 30 12:24:24 2011 +0200

    Remove GLIBMM_EXCEPTIONS_ENABLED ifdefs.
    
    * libgda/src/*.[hg|ccg]: These ifdefs are no longer useful. They were already
    removed from other projects a while ago.

 ChangeLog                      |    7 +
 libgda/src/batch.ccg           |   15 +--
 libgda/src/batch.hg            |    4 -
 libgda/src/connection.ccg      |  264 ++-------------------------------------
 libgda/src/connection.hg       |   87 -------------
 libgda/src/datamodel.ccg       |   11 +--
 libgda/src/datamodel.hg        |    5 -
 libgda/src/holder.hg           |   14 --
 libgda/src/metastore.ccg       |   30 +----
 libgda/src/metastore.hg        |   16 +--
 libgda/src/quarklist.ccg       |    4 -
 libgda/src/serveroperation.ccg |   58 ++--------
 libgda/src/serveroperation.hg  |   39 +------
 libgda/src/serverprovider.ccg  |   10 +--
 libgda/src/serverprovider.hg   |    4 -
 libgda/src/set.ccg             |    8 --
 libgda/src/set.hg              |   10 +--
 libgda/src/sqlparser.ccg       |   37 ------
 libgda/src/sqlparser.hg        |   18 +---
 libgda/src/statement.ccg       |   41 +------
 libgda/src/statement.hg        |   18 ---
 libgda/src/xatransaction.ccg   |   18 ---
 libgda/src/xatransaction.hg    |    8 --
 23 files changed, 50 insertions(+), 676 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index 94a20d2..7687c3f 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2011-03-30  Murray Cumming  <murrayc murrayc com>
+
+	Remove GLIBMM_EXCEPTIONS_ENABLED ifdefs.
+
+	* libgda/src/*.[hg|ccg]: These ifdefs are no longer useful. They were already
+	removed from other projects a while ago.
+
 4.99.0.1:
 
 2011-03-30  Murray Cumming  <murrayc murrayc com>
diff --git a/libgda/src/batch.ccg b/libgda/src/batch.ccg
index c8a4e90..b4e61e9 100644
--- a/libgda/src/batch.ccg
+++ b/libgda/src/batch.ccg
@@ -33,23 +33,16 @@ namespace Gda
 typedef Batch::StatementVector StatementVector;
 
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 bool Batch::get_parameters(Glib::RefPtr<Set>& out_params)
-#else
-bool Batch::get_parameters(Glib::RefPtr<Set>& out_params, std::auto_ptr<Glib::Error>& error)
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 {
   GError* gerror = 0;
   GdaSet* set = 0;
-  bool retval = gda_batch_get_parameters(gobj(), &set, &gerror);
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
+  const bool retval = gda_batch_get_parameters(gobj(), &set, &gerror);
+
   if(gerror)
     ::Glib::Error::throw_exception(gerror);
-#else
-  if(gerror)
-    error = ::Glib::Error::throw_exception(gerror);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
-  if (set)
+
+  if(set)
   {
     out_params = Glib::wrap(set);
   }
diff --git a/libgda/src/batch.hg b/libgda/src/batch.hg
index 8bd229e..1a70314 100644
--- a/libgda/src/batch.hg
+++ b/libgda/src/batch.hg
@@ -59,11 +59,7 @@ public:
   _WRAP_METHOD(StatementVector get_statements() const, gda_batch_get_statements)
 
   _WRAP_METHOD_DOCS_ONLY(gda_statement_get_parameters)
-  #ifdef GLIBMM_EXCEPTIONS_ENABLED
   bool get_parameters(Glib::RefPtr<Set>& out_params);
-  #else
-  bool get_parameters(Glib::RefPtr<Set>& out_params, std::auto_ptr<Glib::Error>& error);
-  #endif //GLIBMM_EXCEPTIONS_ENABLED
     
   // FIXME: Use better marshaller in libgda. TODO: Bug number?
   #m4 _CONVERSION(`GObject*',`Glib::RefPtr<Statement>',`Glib::wrap(GDA_STATEMENT($3))')
diff --git a/libgda/src/connection.ccg b/libgda/src/connection.ccg
index 180df04..e4af5f0 100644
--- a/libgda/src/connection.ccg
+++ b/libgda/src/connection.ccg
@@ -45,18 +45,10 @@ Connection::~Connection()
   }
 }
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 Glib::RefPtr<Connection> Connection::open_from_string(const Glib::ustring& provider_name,
                                                        const Glib::ustring& cnc_string,
                                                        const Glib::ustring& auth_string,
                                                        ConnectionOptions options)
-#else
-Glib::RefPtr<Connection> Connection::open_from_string(const Glib::ustring& provider_name,
-                                                       const Glib::ustring& cnc_string,
-                                                       const Glib::ustring& auth_string,
-                                                       ConnectionOptions options,
-                                                       std::auto_ptr<Glib::Error>& error)
-#endif
 {
   GError* gerror = 0;
   Glib::RefPtr<Connection> retval = Glib::wrap(gda_connection_open_from_string(provider_name.c_str(),
@@ -64,14 +56,8 @@ Glib::RefPtr<Connection> Connection::open_from_string(const Glib::ustring& provi
                                                                                 auth_string.c_str(),
                                                                                 (GdaConnectionOptions)options,
                                                                                 &gerror));
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   if(gerror)
     ::Glib::Error::throw_exception(gerror);
-#else
-  if(gerror)
-    error = ::Glib::Error::throw_exception(gerror);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
-
   return retval;
 }
 
@@ -82,24 +68,15 @@ void Connection::close()
   gda_connection_close(gobj());
 }
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 Glib::RefPtr<Glib::Object> Connection::statement_execute(const Glib::RefPtr<const Statement>& cmd, const Glib::RefPtr<const Set>& params, StatementModelUsage model_usage, Glib::RefPtr<const Set>& last_inserted_row)
-#else
-Glib::RefPtr<Glib::Object> Connection::statement_execute(const Glib::RefPtr<const Statement>& cmd, const Glib::RefPtr<const Set>& params, StatementModelUsage model_usage, Glib::RefPtr<const Set>& last_inserted_row, std::auto_ptr<Glib::Error>& error)
-#endif // GLIBMM_EXCEPTIONS_ENABLED
 {
   GError* gerror = 0;
   GdaSet* lir = 0;
   Glib::RefPtr<Glib::Object> retval = Glib::wrap(
     gda_connection_statement_execute(gobj(), const_cast<GdaStatement*>(cmd->gobj()), const_cast<GdaSet*>(Glib::unwrap(params)), (GdaStatementModelUsage)model_usage, &lir, &gerror));
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   if(gerror)
     ::Glib::Error::throw_exception(gerror);
-#else
-  if(gerror)
-    error = ::Glib::Error::throw_exception(gerror);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 
   if(lir)
     last_inserted_row = Glib::wrap(lir);
@@ -107,44 +84,25 @@ Glib::RefPtr<Glib::Object> Connection::statement_execute(const Glib::RefPtr<cons
   return retval;
 }
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 Glib::RefPtr<Glib::Object> Connection::statement_execute(const Glib::RefPtr<const Statement>& stmt, StatementModelUsage model_usage)
-#else
-Glib::RefPtr<Glib::Object> Connection::statement_execute(const Glib::RefPtr<const Statement>& stmt, StatementModelUsage model_usage, std::auto_ptr<Glib::Error>& error)
-#endif // GLIBMM_EXCEPTIONS_ENABLED
 {
   GError* gerror = 0;
   Glib::RefPtr<Glib::Object> retval = Glib::wrap(
     gda_connection_statement_execute(gobj(), const_cast<GdaStatement*>(Glib::unwrap(stmt)), 0, (GdaStatementModelUsage)model_usage, 0, &gerror));
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   if(gerror)
     ::Glib::Error::throw_exception(gerror);
-#else
-  if(gerror)
-    error = ::Glib::Error::throw_exception(gerror);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 
   return retval;
 }
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 Glib::RefPtr<Glib::Object> Connection::statement_execute(const Glib::ustring& sql, StatementModelUsage model_usage)
-#else
-Glib::RefPtr<Glib::Object> Connection::statement_execute(const Glib::ustring& sql, StatementModelUsage model_usage, std::auto_ptr<Glib::Error>& error)
-#endif // GLIBMM_EXCEPTIONS_ENABLED
 {
   Glib::RefPtr<const Statement> stmt;
   Glib::RefPtr<SqlParser> parser = create_parser();
   if(parser)
   {
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
     stmt = parser->parse_string(sql);
-#else
-    stmt = parser->parse_string(sql, error);
-    if(error.get())
-      return Glib::RefPtr<Glib::Object>();
-#endif
   }
   else
     std::cerr << "Gda::Connection::statement_execute(): Couldn't create parser" << std::endl;
@@ -152,30 +110,17 @@ Glib::RefPtr<Glib::Object> Connection::statement_execute(const Glib::ustring& sq
   if(!stmt)
     return Glib::RefPtr<Glib::Object>();
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
-    return statement_execute(stmt, model_usage);
-#else
-    return statement_execute(stmt, model_usage, error);
-#endif
+  return statement_execute(stmt, model_usage);
 }
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 int Connection::statement_execute_non_select(const Glib::RefPtr<const Statement>& cmd, const Glib::RefPtr<const Set>& params, Glib::RefPtr<const Set>& last_inserted_row)
-#else
-int Connection::statement_execute_non_select(const Glib::RefPtr<const Statement>& cmd, const Glib::RefPtr<const Set>& params, Glib::RefPtr<const Set>& last_inserted_row, std::auto_ptr<Glib::Error>& error)
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 {
   GError* gerror = 0;
   GdaSet* lir = 0;
   const int retval = gda_connection_statement_execute_non_select(gobj(), const_cast<GdaStatement*>(Glib::unwrap(cmd)),  const_cast<GdaSet*>(Glib::unwrap(params)), &lir, &gerror);
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   if(gerror)
     ::Glib::Error::throw_exception(gerror);
-#else
-  if(gerror)
-    error = ::Glib::Error::throw_exception(gerror);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 
   if(lir)
     last_inserted_row = Glib::wrap(lir);
@@ -183,112 +128,56 @@ int Connection::statement_execute_non_select(const Glib::RefPtr<const Statement>
   return retval;
 }
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 int Connection::statement_execute_non_select(const Glib::RefPtr<const Statement>& cmd, const Glib::RefPtr<const Set>& params)
-#else
-int Connection::statement_execute_non_select(const Glib::RefPtr<const Statement>& cmd, const Glib::RefPtr<const Set>& params, std::auto_ptr<Glib::Error>& error)
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 {
   GError* gerror = 0;
   const int retval = gda_connection_statement_execute_non_select(gobj(), const_cast<GdaStatement*>(Glib::unwrap(cmd)),  const_cast<GdaSet*>(Glib::unwrap(params)), 0, &gerror);
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   if(gerror)
     ::Glib::Error::throw_exception(gerror);
-#else
-  if(gerror)
-    error = ::Glib::Error::throw_exception(gerror);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 
   return retval;
 }
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 int Connection::statement_execute_non_select(const Glib::RefPtr<const Statement>& cmd)
-#else
-int Connection::statement_execute_non_select(const Glib::RefPtr<const Statement>& cmd, std::auto_ptr<Glib::Error>& error)
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 {
   GError* gerror = 0;
-  int retval = gda_connection_statement_execute_non_select(gobj(), const_cast<GdaStatement*>(Glib::unwrap(cmd)), 0, 0, &gerror);
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
+  const int retval = gda_connection_statement_execute_non_select(gobj(), const_cast<GdaStatement*>(Glib::unwrap(cmd)), 0, 0, &gerror);
+
   if(gerror)
     ::Glib::Error::throw_exception(gerror);
-#else
-  if(gerror)
-    error = ::Glib::Error::throw_exception(gerror);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 
   return retval;
 }
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 int Connection::statement_execute_non_select_builder(const Glib::RefPtr<const SqlBuilder>& builder)
-#else
-int Connection::statement_execute_non_select_builder(const Glib::RefPtr<const SqlBuilder>& builder, std::auto_ptr<Glib::Error>& error)
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 {
-  Glib::RefPtr<Gnome::Gda::Statement> stmt;
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
-  stmt = builder->get_statement(); //Allow any exceptions to be thrown up to the caller.
-#else
-  stmt = builder->get_statement(error);
-  if(error.get())
-    return 0;
-#endif //GLIBMM_EXCEPTIONS_ENABLED
+  Glib::RefPtr<Gnome::Gda::Statement> stmt = builder->get_statement(); //Allow any exceptions to be thrown up to the caller.
 
   if(!stmt)
      return 0;
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   return statement_execute_non_select(stmt);
-#else
-  return statement_execute_non_select(stmt, error);
-#endif
 }
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 int Connection::statement_execute_non_select_builder(const Glib::RefPtr<const SqlBuilder>& builder, const Glib::RefPtr<const Set>& params)
-#else
-int Connection::statement_execute_non_select_builder(const Glib::RefPtr<const SqlBuilder>& builder, const Glib::RefPtr<const Set>& params, std::auto_ptr<Glib::Error>& error)
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 {
-  Glib::RefPtr<Gnome::Gda::Statement> stmt;
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
-  stmt = builder->get_statement(); //Allow any exceptions to be thrown up to the caller.
-#else
-  stmt = builder->get_statement(error);
-  if(error.get())
-    return 0;
-#endif //GLIBMM_EXCEPTIONS_ENABLED
+  Glib::RefPtr<Gnome::Gda::Statement> stmt = builder->get_statement(); //Allow any exceptions to be thrown up to the caller.
 
   if(!stmt)
      return 0;
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   return statement_execute_non_select(stmt, params);
-#else
-  return statement_execute_non_select(stmt, params, error);
-#endif
 }
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 Glib::ustring Connection::statement_to_sql(const Glib::RefPtr<const Statement>& statement, const Glib::RefPtr<const Set>& params, StatementSqlFlag flags, std::vector< Glib::RefPtr<Holder> >& params_used) const
-#else
-Glib::ustring Connection::statement_to_sql(const Glib::RefPtr<const Statement>& statement, const Glib::RefPtr<const Set>& params, StatementSqlFlag flags, std::vector< Glib::RefPtr<Holder> >& params_used, std::auto_ptr<Glib::Error>& error) const
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 {
   GError* gerror = 0;
   GSList* params_usedc = 0;
   const Glib::ustring retvalue = Glib::convert_return_gchar_ptr_to_ustring(gda_connection_statement_to_sql(const_cast<GdaConnection*>(gobj()), const_cast<GdaStatement*>(Glib::unwrap(statement)), const_cast<GdaSet*>(Glib::unwrap(params)), ((GdaStatementSqlFlag)(flags)), &params_usedc, &(gerror)));
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   if(gerror)
     ::Glib::Error::throw_exception(gerror);
-#else
-  if(gerror)
-    error = ::Glib::Error::throw_exception(gerror);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 
   std::vector< Glib::RefPtr<Holder> > params_usedcpp
     = Glib::SListHandler< Glib::RefPtr<Holder> >::slist_to_vector(params_usedc, Glib::OWNERSHIP_SHALLOW);
@@ -301,113 +190,57 @@ Glib::ustring Connection::statement_to_sql(const Glib::RefPtr<const Statement>&
   return retvalue;
 }
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 Glib::RefPtr<DataModel> Connection::statement_execute_select(const Glib::RefPtr<const Statement>& stmt, StatementModelUsage model_usage)
-#else
-Glib::RefPtr<DataModel> Connection::statement_execute_select(const Glib::RefPtr<const Statement>& stmt, StatementModelUsage model_usage, std::auto_ptr<Glib::Error>& error)
-#endif
 {
   GError* gerror = 0;
   Glib::RefPtr<DataModel> retvalue = Glib::wrap(gda_connection_statement_execute_select_full(gobj(), const_cast<GdaStatement*>(Glib::unwrap(stmt)), 0 /* params */, ((GdaStatementModelUsage)(model_usage)), 0 /* col_types */, &(gerror)));
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
+
   if(gerror)
     ::Glib::Error::throw_exception(gerror);
-#else
-  if(gerror)
-    error = ::Glib::Error::throw_exception(gerror);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 
   return retvalue;
 }
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 Glib::RefPtr<DataModel> Connection::statement_execute_select(const Glib::RefPtr<const Statement>& stmt, const Glib::RefPtr<const Set>& params, StatementModelUsage model_usage)
-#else
-Glib::RefPtr<DataModel> Connection::statement_execute_select(const Glib::RefPtr<const Statement>& stmt, const Glib::RefPtr<const Set>& params, StatementModelUsage model_usage, std::auto_ptr<Glib::Error>& error)
-#endif
 {
   GError* gerror = 0;
   Glib::RefPtr<DataModel> retvalue = Glib::wrap(gda_connection_statement_execute_select_full(gobj(), const_cast<GdaStatement*>(Glib::unwrap(stmt)), const_cast<GdaSet*>(Glib::unwrap(params)), ((GdaStatementModelUsage)(model_usage)), 0 /* col_types */, &(gerror)));
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
+
   if(gerror)
     ::Glib::Error::throw_exception(gerror);
-#else
-  if(gerror)
-    error = ::Glib::Error::throw_exception(gerror);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 
   return retvalue;
 }
 
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 Glib::RefPtr<DataModel> Connection::statement_execute_select_builder(const Glib::RefPtr<const SqlBuilder>& builder, StatementModelUsage model_usage)
-#else
-Glib::RefPtr<DataModel> Connection::statement_execute_select_builder(const Glib::RefPtr<const SqlBuilder>& builder, StatementModelUsage model_usage, std::auto_ptr<Glib::Error>& error)
-#endif
 {
-  Glib::RefPtr<Gnome::Gda::Statement> stmt;
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
-  stmt = builder->get_statement(); //Allow any exceptions to be thrown up to the caller.
-#else
-  stmt = builder->get_statement(error);
-  if(error.get())
-    return Glib::RefPtr<DataModel>();
-#endif //GLIBMM_EXCEPTIONS_ENABLED
+  Glib::RefPtr<Gnome::Gda::Statement> stmt = builder->get_statement(); //Allow any exceptions to be thrown up to the caller.
 
   if(!stmt)
      return Glib::RefPtr<DataModel>();
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   return statement_execute_select(stmt, model_usage);
-#else
-  return statement_execute_select(stmt, model_usage, error);
-#endif
 }
 
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 Glib::RefPtr<DataModel> Connection::statement_execute_select_builder(const Glib::RefPtr<const SqlBuilder>& builder, const Glib::RefPtr<const Set>& params, StatementModelUsage model_usage)
-#else
-Glib::RefPtr<DataModel> Connection::statement_execute_select_builder(const Glib::RefPtr<const SqlBuilder>& builder, const Glib::RefPtr<const Set>& params, StatementModelUsage model_usage, std::auto_ptr<Glib::Error>& error)
-#endif
 {
-  Glib::RefPtr<Gnome::Gda::Statement> stmt;
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
-  stmt = builder->get_statement(); //Allow any exceptions to be thrown up to the caller.
-#else
-  stmt = builder->get_statement(error);
-  if(error.get())
-    return Glib::RefPtr<DataModel>();
-#endif //GLIBMM_EXCEPTIONS_ENABLED
+  Glib::RefPtr<Gnome::Gda::Statement> stmt = builder->get_statement(); //Allow any exceptions to be thrown up to the caller.
 
   if(!stmt)
      return Glib::RefPtr<DataModel>();
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   return statement_execute_select(stmt, params, model_usage);
-#else
-  return statement_execute_select(stmt, params, model_usage, error);
-#endif
 }
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 Glib::RefPtr<DataModel> Connection::statement_execute_select(const Glib::ustring& sql, StatementModelUsage model_usage)
-#else
-Glib::RefPtr<DataModel> Connection::statement_execute_select(const Glib::ustring& sql, StatementModelUsage model_usage, std::auto_ptr<Glib::Error>& error)
-#endif // GLIBMM_EXCEPTIONS_ENABLED
 {
   Glib::RefPtr<const Statement> stmt;
   Glib::RefPtr<SqlParser> parser = create_parser();
   if(parser)
   {
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
     stmt = parser->parse_string(sql);
-#else
-    stmt = parser->parse_string(sql, error);
-    if(error.get())
-      return Glib::RefPtr<DataModel>();
-#endif
   }
 
   if(!stmt)
@@ -415,34 +248,20 @@ Glib::RefPtr<DataModel> Connection::statement_execute_select(const Glib::ustring
 
   GError* gerror = 0;
   Glib::RefPtr<DataModel> retvalue = Glib::wrap(gda_connection_statement_execute_select_full(gobj(), const_cast<GdaStatement*>(Glib::unwrap(stmt)), 0 /* params */, ((GdaStatementModelUsage)(model_usage)), 0 /* col_types */, &(gerror)));
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
+
   if(gerror)
     ::Glib::Error::throw_exception(gerror);
-#else
-  if(gerror)
-    error = ::Glib::Error::throw_exception(gerror);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 
   return retvalue;
 }
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 Glib::RefPtr<DataModel> Connection::statement_execute_select(const Glib::ustring& sql, const Glib::RefPtr<const Set>& params, StatementModelUsage model_usage)
-#else
-Glib::RefPtr<DataModel> Connection::statement_execute_select(const Glib::ustring& sql, const Glib::RefPtr<const Set>& params, StatementModelUsage model_usage, std::auto_ptr<Glib::Error>& error)
-#endif // GLIBMM_EXCEPTIONS_ENABLED
 {
   Glib::RefPtr<const Statement> stmt;
   Glib::RefPtr<SqlParser> parser = create_parser();
   if(parser)
   {
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
     stmt = parser->parse_string(sql);
-#else
-    stmt = parser->parse_string(sql, error);
-    if(error.get())
-      return Glib::RefPtr<DataModel>();
-#endif
   }
 
   if(!stmt)
@@ -450,81 +269,49 @@ Glib::RefPtr<DataModel> Connection::statement_execute_select(const Glib::ustring
 
   GError* gerror = 0;
   Glib::RefPtr<DataModel> retvalue = Glib::wrap(gda_connection_statement_execute_select_full(gobj(), const_cast<GdaStatement*>(Glib::unwrap(stmt)), const_cast<GdaSet*>(Glib::unwrap(params)), ((GdaStatementModelUsage)(model_usage)), 0 /* col_types */, &(gerror)));
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
+
   if(gerror)
     ::Glib::Error::throw_exception(gerror);
-#else
-  if(gerror)
-    error = ::Glib::Error::throw_exception(gerror);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 
   return retvalue;
 }
 
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 bool Connection::update_meta_store()
-#else
-bool Connection::update_meta_store(std::auto_ptr<Glib::Error>& error)
-#endif
 {
   GError* gerror = 0;
   const bool retvalue = gda_connection_update_meta_store(gobj(), 0, &gerror);
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
+
   if(gerror)
     ::Glib::Error::throw_exception(gerror);
-#else
-  if(gerror)
-    error = ::Glib::Error::throw_exception(gerror);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 
   return retvalue;
 }
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 bool Connection::update_meta_store(const Glib::ustring& id)
-#else
-bool Connection::update_meta_store(const Glib::ustring& id, std::auto_ptr<Glib::Error>& error)
-#endif
 {
   GError* gerror = 0;
   GdaMetaContext mcontext = {const_cast<gchar*>(id.c_str()), 1, 0, 0};
   const bool retvalue = gda_connection_update_meta_store(gobj(), &mcontext, &gerror);
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
+
   if(gerror)
     ::Glib::Error::throw_exception(gerror);
-#else
-  if(gerror)
-    error = ::Glib::Error::throw_exception(gerror);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 
   return retvalue;
 }
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 Glib::RefPtr<DataModel> Connection::get_meta_store_data(ConnectionMetaType meta_type)
-#else
-Glib::RefPtr<DataModel> Connection::get_meta_store_data(ConnectionMetaType meta_type, std::auto_ptr<Glib::Error>& error)
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 {
   GError* gerror = 0;
   Glib::RefPtr<DataModel> retvalue = Glib::wrap(gda_connection_get_meta_store_data_v(gobj(), ((GdaConnectionMetaType)(meta_type)), 0, &(gerror)));
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
+
   if(gerror)
     ::Glib::Error::throw_exception(gerror);
-#else
-  if(gerror)
-    error = ::Glib::Error::throw_exception(gerror);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 
   return retvalue;
 }
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 bool Connection::update_meta_store_table(const Glib::ustring& table_name, const Glib::ustring& schema_name)
-#else
-bool Connection::update_meta_store_table(const Glib::ustring& table_name, const Glib::ustring& schema_name, std::auto_ptr<Glib::Error>& error)
-#endif
 {
   // This function is needed to make sure that
   // the GdaMetaStore really gets the meta data for the table we specified, even if
@@ -552,22 +339,13 @@ bool Connection::update_meta_store_table(const Glib::ustring& table_name, const
 
   g_free(table_name_quoted);
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   if(gerror)
     ::Glib::Error::throw_exception(gerror);
-#else
-  if(gerror)
-    error = ::Glib::Error::throw_exception(gerror);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 
   return retval;
 }
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 bool Connection::update_meta_store_table_names(const Glib::ustring& schema_name)
-#else
-bool Connection::update_meta_store_table_names(const Glib::ustring& schema_name, std::auto_ptr<Glib::Error>& error)
-#endif
 {
   GValue table_schema_value = { 0 };
   g_value_init(&table_schema_value, G_TYPE_STRING);
@@ -582,34 +360,20 @@ bool Connection::update_meta_store_table_names(const Glib::ustring& schema_name,
 
   g_value_unset(&table_schema_value);
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   if(gerror)
     ::Glib::Error::throw_exception(gerror);
-#else
-  if(gerror)
-    error = ::Glib::Error::throw_exception(gerror);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 
   return retval;
 }
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 bool Connection::update_meta_store_data_types()
-#else
-bool Connection::update_meta_store_data_types(std::auto_ptr<Glib::Error>& error)
-#endif
 {
   GdaMetaContext mcontext = {(gchar*)"_builtin_data_types", 0, 0, 0 };
   GError* gerror = 0;
   const bool retval = gda_connection_update_meta_store(gobj(), &mcontext, &gerror);
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   if(gerror)
     ::Glib::Error::throw_exception(gerror);
-#else
-  if(gerror)
-    error = ::Glib::Error::throw_exception(gerror);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 
   return retval;
 }
diff --git a/libgda/src/connection.hg b/libgda/src/connection.hg
index 2d946b9..e8d9797 100644
--- a/libgda/src/connection.hg
+++ b/libgda/src/connection.hg
@@ -72,18 +72,10 @@ public:
 
   /* This throws an error which we don't want to do in a constructor */
   _WRAP_METHOD_DOCS_ONLY(gda_connection_open_from_string)
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   static Glib::RefPtr<Connection> open_from_string(const Glib::ustring& provider_name,
                                                     const Glib::ustring& cnc_string,
                                                     const Glib::ustring& auth_string = Glib::ustring(),
                                                     ConnectionOptions options = CONNECTION_OPTIONS_NONE);
-#else
-  static Glib::RefPtr<Connection> open_from_string(const Glib::ustring& provider_name,
-                                                    const Glib::ustring& cnc_string,
-                                                    const Glib::ustring& auth_string,
-                                                    ConnectionOptions options,
-                                                    std::auto_ptr<Glib::Error>& error);
-#endif
 
   _WRAP_METHOD(bool open(), gda_connection_open, errthrow)
 
@@ -114,25 +106,13 @@ public:
 
   _WRAP_METHOD_DOCS_ONLY(gda_connection_statement_execute)
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   Glib::RefPtr<Glib::Object> statement_execute(const Glib::RefPtr<const Statement>& stmt, const Glib::RefPtr<const Set>& params, StatementModelUsage model_usage, Glib::RefPtr<const Set>& last_insert_row);
-#else
-  Glib::RefPtr<Glib::Object> statement_execute(const Glib::RefPtr<const Statement>& stmt, const Glib::RefPtr<const Set>& params, StatementModelUsage model_usage, Glib::RefPtr<const Set>& last_insert_row, std::auto_ptr<Glib::Error>& error);
-#endif // GLIBMM_EXCEPTIONS_ENABLED
 
 //TODO: Documentation:
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   Glib::RefPtr<Glib::Object> statement_execute(const Glib::RefPtr<const Statement>& stmt, StatementModelUsage model_usage = STATEMENT_MODEL_RANDOM_ACCESS);
-#else
-  Glib::RefPtr<Glib::Object> statement_execute(const Glib::RefPtr<const Statement>& stmt, StatementModelUsage model_usage, std::auto_ptr<Glib::Error>& error);
-#endif // GLIBMM_EXCEPTIONS_ENABLED
 
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   Glib::RefPtr<Glib::Object> statement_execute(const Glib::ustring& sql, StatementModelUsage model_usage = STATEMENT_MODEL_RANDOM_ACCESS);
-#else
-  Glib::RefPtr<Glib::Object> statement_execute(const Glib::ustring& sql, StatementModelUsage model_usage, std::auto_ptr<Glib::Error>& error);
-#endif // GLIBMM_EXCEPTIONS_ENABLED
 
   //_WRAP_METHOD(Glib::RefPtr<DataModel> statement_execute_select(const Glib::RefPtr<const Statement>& stmt, const Glib::RefPtr<const Set>& params), gda_connection_statement_execute_select, errthrow)
   _IGNORE(gda_connection_statement_execute_select) //We instead create a version that can take an optional usage parameter too.
@@ -143,81 +123,43 @@ public:
 
 //This custom-written method has more optional methods than gda_connection_execute_select_command().
 //TODO: Documentation:
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   Glib::RefPtr<DataModel> statement_execute_select(const Glib::RefPtr<const Statement>& stmt, StatementModelUsage model_usage = STATEMENT_MODEL_RANDOM_ACCESS);
   Glib::RefPtr<DataModel> statement_execute_select(const Glib::ustring& sql, StatementModelUsage model_usage = STATEMENT_MODEL_RANDOM_ACCESS);
-#else
-  Glib::RefPtr<DataModel> statement_execute_select(const Glib::RefPtr<const Statement>& stmt, StatementModelUsage model_usage, std::auto_ptr<Glib::Error>& error);
-  Glib::RefPtr<DataModel> statement_execute_select(const Glib::ustring& sql, StatementModelUsage model_usage, std::auto_ptr<Glib::Error>& error);
-#endif
 
 //This custom-written method has more optional methods than gda_connection_execute_select_command().
 //TODO: Documentation:
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   Glib::RefPtr<DataModel> statement_execute_select(const Glib::RefPtr<const Statement>& stmt, const Glib::RefPtr<const Set>& params, StatementModelUsage model_usage = STATEMENT_MODEL_RANDOM_ACCESS);
   Glib::RefPtr<DataModel> statement_execute_select(const Glib::ustring& sql, const Glib::RefPtr<const Set>& params, StatementModelUsage model_usage = STATEMENT_MODEL_RANDOM_ACCESS);
-#else
-  Glib::RefPtr<DataModel> statement_execute_select(const Glib::RefPtr<const Statement>& stmt, const Glib::RefPtr<const Set>& params, StatementModelUsage model_usage, std::auto_ptr<Glib::Error>& error);
-  Glib::RefPtr<DataModel> statement_execute_select(const Glib::ustring& sql, const Glib::RefPtr<const Set>& params, StatementModelUsage model_usage, std::auto_ptr<Glib::Error>& error);
-#endif
   _IGNORE(gda_connection_execute_select_command)
 
 
 //TODO: Documentation:
 //Note that we add the prefix _builder() because overloading on different RefPtr<> types seems to be ambiguous.
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   Glib::RefPtr<DataModel> statement_execute_select_builder(const Glib::RefPtr<const SqlBuilder>& stmt, StatementModelUsage model_usage = STATEMENT_MODEL_RANDOM_ACCESS);
-#else
-  Glib::RefPtr<DataModel> statement_execute_select_builder(const Glib::RefPtr<const SqlBuilder>& stmt, StatementModelUsage model_usage, std::auto_ptr<Glib::Error>& error);
-#endif
 
 //TODO: Documentation:
 //Note that we add the prefix _builder() because overloading on different RefPtr<> types seems to be ambiguous.
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   Glib::RefPtr<DataModel> statement_execute_select_builder(const Glib::RefPtr<const SqlBuilder>& stmt, const Glib::RefPtr<const Set>& params, StatementModelUsage model_usage = STATEMENT_MODEL_RANDOM_ACCESS);
-#else
-  Glib::RefPtr<DataModel> statement_execute_select_builder(const Glib::RefPtr<const SqlBuilder>& stmt, const Glib::RefPtr<const Set>& params, StatementModelUsage model_usage, std::auto_ptr<Glib::Error>& error);
-#endif
 
 
   _WRAP_METHOD_DOCS_ONLY(gda_connection_statement_execute_non_select)
 //TODO: Documentation:
 //TODO: It's not nice that these two method overloads differ only by the constness of the set.
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   int statement_execute_non_select(const Glib::RefPtr<const Statement>& stmt, const Glib::RefPtr<const Set>& params, Glib::RefPtr<const Set>& last_insert_row);
-#else
-  int statement_execute_non_select(const Glib::RefPtr<const Statement>& stmt, const Glib::RefPtr<const Set>& params, Glib::RefPtr<const Set>& last_insert_row, std::auto_ptr<Glib::Error>& error);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 
 //TODO: Documentation:
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   int statement_execute_non_select(const Glib::RefPtr<const Statement>& stmt, const Glib::RefPtr<const Set>& params);
-#else
-  int statement_execute_non_select(const Glib::RefPtr<const Statement>& stmt, const Glib::RefPtr<const Set>& params, std::auto_ptr<Glib::Error>& error);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 
 //TODO: Documentation:
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   int statement_execute_non_select(const Glib::RefPtr<const Statement>& stmt);
-#else
-  int statement_execute_non_select(const Glib::RefPtr<const Statement>& stmt, std::auto_ptr<Glib::Error>& error);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 
   _WRAP_METHOD(int statement_execute_non_select(const Glib::ustring& sql), gda_connection_execute_non_select_command, errthrow)
 
 //TODO: Documentation:
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   int statement_execute_non_select_builder(const Glib::RefPtr<const SqlBuilder>& builder);
-#else
-  int statement_execute_non_select_builder(const Glib::RefPtr<const SqlBuilder>& builder, std::auto_ptr<Glib::Error>& error);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 
 //TODO: Documentation:
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   int statement_execute_non_select_builder(const Glib::RefPtr<const SqlBuilder>& builder, const Glib::RefPtr<const Set>& params);
-#else
-  int statement_execute_non_select_builder(const Glib::RefPtr<const SqlBuilder>& builder, const Glib::RefPtr<const Set>& params, std::auto_ptr<Glib::Error>& error);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 
   _WRAP_METHOD(guint async_statement_execute(const Glib::RefPtr<const Statement>& stmt, const Glib::RefPtr<const Set>& params, StatementModelUsage model_usage, const std::vector<GType>& col_types, bool need_last_insert_row = false), gda_connection_async_statement_execute, errthrow)
 
@@ -276,19 +218,13 @@ public:
 
   _WRAP_METHOD(Glib::ustring get_provider_name() const, gda_connection_get_provider_name)
 
-
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   /** Update the full meta store information.
    *
    * Note that this may take some time for big databases
    * @return <tt>true</tt> if no error occurred.
    */
   bool update_meta_store();
-#else
-  bool update_meta_store(std::auto_ptr<Glib::Error>& err);
-#endif
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   /** Update the meta store information @a id
    *
    * This can speed up the update of the meta store if you only need a
@@ -297,12 +233,8 @@ public:
    * @return <tt>true</tt> if no error occurred.
    */
   bool update_meta_store(const Glib::ustring& id);
-#else
-  bool update_meta_store(const Glib::ustring& id, std::auto_ptr<Glib::Error>& err);
-#endif
   _IGNORE(gda_connection_update_meta_store)
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   /** Update the meta store information for the table named @a table_name
    *
    * This can speed up the update of the meta store if you only need the information
@@ -316,11 +248,7 @@ public:
    * @return <tt>true</tt> if no error occurred.
    */
   bool update_meta_store_table(const Glib::ustring& table_name, const Glib::ustring& schema_name = Glib::ustring());
-#else
-  bool update_meta_store_table(const Glib::ustring& table_name, const Glib::ustring& schema_name, std::auto_ptr<Glib::Error>& err);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   /** Update the meta store information for the table names.
    *
    * This can speed up the update of the meta store if you only need the list of table names.
@@ -335,11 +263,7 @@ public:
    * @return <tt>true</tt> if no error occurred.
    */
   bool update_meta_store_table_names(const Glib::ustring& schema_name = Glib::ustring());
-#else
-  bool update_meta_store_table_names(const Glib::ustring& schema_name, std::auto_ptr<Glib::Error>& err);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   /** Update the meta store information for the data types.
    *
    * This can speed up the update of the meta store if you only need the data types.
@@ -347,9 +271,6 @@ public:
    * @return <tt>true</tt> if no error occurred.
    */
   bool update_meta_store_data_types();
-#else
-  bool update_meta_store_data_types(std::auto_ptr<Glib::Error>& err);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 
   _WRAP_METHOD(bool statement_prepare(const Glib::RefPtr<const Statement>& stmt), gda_connection_statement_prepare, errthrow)
 
@@ -358,11 +279,7 @@ public:
   _WRAP_METHOD(Glib::RefPtr<DataModel> get_meta_store_data(ConnectionMetaType meta_type, const std::vector< Glib::RefPtr<Holder> >& filters), gda_connection_get_meta_store_data_v, errthrow)
   _IGNORE(gda_connection_get_meta_store_data)
 
-  #ifdef GLIBMM_EXCEPTIONS_ENABLED
   Glib::RefPtr<DataModel> get_meta_store_data(ConnectionMetaType meta_type);
-  #else
-  Glib::RefPtr<DataModel> get_meta_store_data(ConnectionMetaType meta_type, std::auto_ptr<Glib::Error>& error);
-  #endif //GLIBMM_EXCEPTIONS_ENABLED
 
   _WRAP_METHOD(Glib::RefPtr<MetaStore> get_meta_store(), gda_connection_get_meta_store, refreturn)
   _WRAP_METHOD(Glib::RefPtr<const MetaStore> get_meta_store() const, gda_connection_get_meta_store, constversion)
@@ -381,11 +298,7 @@ public:
   _WRAP_METHOD_DOCS_ONLY(gda_connection_statement_to_sql)
 
   //TODO: Add an overload without the params_used.
-  #ifdef GLIBMM_EXCEPTIONS_ENABLED
   Glib::ustring statement_to_sql(const Glib::RefPtr<const Statement>& stmt, const Glib::RefPtr<const Set>& params, StatementSqlFlag flags, std::vector< Glib::RefPtr<Holder> >& params_used) const;
-  #else
-  Glib::ustring statement_to_sql(const Glib::RefPtr<const Statement>& stmt, const Glib::RefPtr<const Set>& params, StatementSqlFlag flags, std::vector< Glib::RefPtr<Holder> >& params_used, std::auto_ptr<Glib::Error>& error) const;
-  #endif //GLIBMM_EXCEPTIONS_ENABLED
 
   _IGNORE(gda_connection_internal_reset_transaction_status)
 
diff --git a/libgda/src/datamodel.ccg b/libgda/src/datamodel.ccg
index 9de8b0e..146f768 100644
--- a/libgda/src/datamodel.ccg
+++ b/libgda/src/datamodel.ccg
@@ -34,21 +34,14 @@ namespace Gnome
 namespace Gda
 {
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
+
 bool DataModel::export_to_file(DataModelIOFormat format, const std::string& file, const std::vector<int>& cols, const std::vector<int>& rows, const Glib::RefPtr<Set>& options)
-#else
-bool DataModel::export_to_file(DataModelIOFormat format, const std::string& file, const std::vector<int>& cols, const std::vector<int>& rows, const Glib::RefPtr<Set>& options, std::auto_ptr<Glib::Error>& error)
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 {
   GError* gerror = 0;
   bool retvalue = gda_data_model_export_to_file(gobj(), static_cast<GdaDataModelIOFormat>(format), file.c_str(), cols.data(), cols.size(), rows.data(), rows.size(), options->gobj(), &gerror);
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
+
   if(gerror)
     ::Glib::Error::throw_exception(gerror);
-#else
-  if(gerror)
-    error = ::Glib::Error::throw_exception(gerror);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 
   return retvalue;
 }
diff --git a/libgda/src/datamodel.hg b/libgda/src/datamodel.hg
index 7ae57fa..e245c2b 100644
--- a/libgda/src/datamodel.hg
+++ b/libgda/src/datamodel.hg
@@ -163,12 +163,7 @@ public:
    * @param options List of options for the export.
    * @result true if no error occurred.
    */
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   bool export_to_file(DataModelIOFormat format, const std::string& file, const std::vector<int>& cols, const std::vector<int>& rows, const Glib::RefPtr<Set>& options);
-#else
-  bool export_to_file(DataModelIOFormat format, const std::string& file, const std::vector<int>& cols, const std::vector<int>& rows, const Glib::RefPtr<Set>& options, std::auto_ptr<Glib::Error>& error);
-#endif
-  _IGNORE(gda_data_model_export_to_file)
 
   //TODO: Avoid use of C GHashTable?
   _WRAP_METHOD(bool import_from_model(const Glib::RefPtr<DataModel>& from,  bool overwrite, GHashTable *cols_trans), gda_data_model_import_from_model, errthrow)
diff --git a/libgda/src/holder.hg b/libgda/src/holder.hg
index 6717045..f399456 100644
--- a/libgda/src/holder.hg
+++ b/libgda/src/holder.hg
@@ -62,13 +62,8 @@ public:
   _WRAP_METHOD(bool set_value_as_value(const Value& value), gda_holder_set_value, errthrow)
 
   //TODO: Documentation:
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   template <class ValueType>
   bool set_value(const ValueType& value);
-#else
-  template <class ValueType>
-  bool set_value(const ValueType& value, std::auto_ptr<Glib::Error>& error);
-#endif
 
   _WRAP_METHOD(bool set_value_str(const Glib::RefPtr<DataHandler>& dh, const Glib::ustring& value), gda_holder_set_value_str, errthrow)
   _WRAP_METHOD(bool take_value(const Value& value), gda_holder_take_value, errthrow)
@@ -123,21 +118,12 @@ public:
 };
 
 #ifndef DOXYGEN_SHOULD_SKIP_THIS
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 template <class ValueType> inline
 bool Holder::set_value(const ValueType& value)
 {
   Gnome::Gda::Value gdavalue(value);
   return this->set_value_as_value(gdavalue);
 }
-#else
-template <class ValueType> inline
-bool Holder::set_value(const ValueType& value, std::auto_ptr<Glib::Error>& error)
-{
-  Gnome::Gda::Value gdavalue(value);
-  return this->set_value_as_value(gdavalue, error);
-}
-#endif
 #endif //DOXYGEN_SHOULD_SKIP_THIS
 
 } // namespace Gda
diff --git a/libgda/src/metastore.ccg b/libgda/src/metastore.ccg
index 60e993d..9eeb37b 100644
--- a/libgda/src/metastore.ccg
+++ b/libgda/src/metastore.ccg
@@ -29,60 +29,36 @@ namespace Gnome
 namespace Gda
 {
   
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 Glib::RefPtr<DataModel> MetaStore::extract(const Glib::ustring& sql)
-#else
-Glib::RefPtr<DataModel> MetaStore::extract(const Glib::ustring& sql, std::auto_ptr<Glib::Error>& error)
-#endif
 {
   GError* gerror = 0;
   Glib::RefPtr<DataModel> retval = Glib::wrap(gda_meta_store_extract(gobj(), sql.c_str(), &gerror));
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
+
   if(gerror)
     ::Glib::Error::throw_exception(gerror);
-#else
-  if(gerror)
-    error = ::Glib::Error::throw_exception(gerror);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 
   return retval;
 }
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 bool MetaStore::modify(const Glib::ustring& sql, const Glib::RefPtr<DataModel>& data_model, const Glib::ustring& condition)
-#else
-bool MetaStore::modify(const Glib::ustring& sql, const Glib::RefPtr<DataModel>& data_model, const Glib::ustring& condition, std::auto_ptr<Glib::Error>& error)
-#endif
 {
   GError* gerror = 0;
   bool retval = static_cast<bool>(gda_meta_store_modify(gobj(), sql.c_str(), Glib::unwrap(data_model), condition.c_str(), &gerror));
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
+
   if(gerror)
     ::Glib::Error::throw_exception(gerror);
-#else
-  if(gerror)
-    error = ::Glib::Error::throw_exception(gerror);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 
   return retval;
 }
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 bool MetaStore::get_attribute_value(const Glib::ustring& att_name, Glib::ustring& att_value)
-#else
-bool MetaStore::get_attribute_value(const Glib::ustring& att_name, Glib::ustring& att_value, std::auto_ptr<Glib::Error> error)
-#endif
 {
   GError* gerror = 0;
   gchar* c_att_value = 0;
   bool retval = gda_meta_store_get_attribute_value(gobj(), att_name.c_str(), &c_att_value, &gerror);
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
+
   if(gerror)
     ::Glib::Error::throw_exception(gerror);
-#else
-  if(gerror)
-    error = ::Glib::Error::throw_exception(gerror);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
   if (c_att_value)
     att_value = c_att_value;
 
diff --git a/libgda/src/metastore.hg b/libgda/src/metastore.hg
index 89c11ee..18deda9 100644
--- a/libgda/src/metastore.hg
+++ b/libgda/src/metastore.hg
@@ -66,18 +66,12 @@ public:
   
   _WRAP_METHOD(int get_version() const, gda_meta_store_get_version)
   _WRAP_METHOD_DOCS_ONLY (gda_meta_store_extract)
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
+
   Glib::RefPtr<DataModel> extract(const Glib::ustring& sql);
-#else
-  Glib::RefPtr<DataModel> extract(const Glib::ustring& sql, std::auto_ptr<Glib::Error>& err);
-#endif  
+
   _WRAP_METHOD_DOCS_ONLY (gda_meta_store_modify)
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   bool modify(const Glib::ustring& sql, const Glib::RefPtr<DataModel>& data_model, const Glib::ustring& condition);
-#else
-  bool modify(const Glib::ustring& sql, const Glib::RefPtr<DataModel>& data_model, const Glib::ustring& condition, std::auto_ptr<Glib::Error>& err);
-#endif
-   
+
   _WRAP_METHOD(bool modify_with_context (MetaContext* context, const Glib::RefPtr<DataModel>& new_data), gda_meta_store_modify_with_context, errthrow)
 
   _WRAP_METHOD(Glib::RefPtr<DataModel> create_modify_data_model(const Glib::ustring& table_name), gda_meta_store_create_modify_data_model)
@@ -89,11 +83,7 @@ public:
   _WRAP_METHOD(std::vector<Glib::ustring> schema_get_depend_tables(const Glib::ustring& table_name), gda_meta_store_schema_get_depend_tables)  
 
   _WRAP_METHOD_DOCS_ONLY(gda_meta_store_get_attribute_value)
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
    bool get_attribute_value(const Glib::ustring& att_name, Glib::ustring& att_value);
-#else
-   bool get_attribute_value(const Glib::ustring& att_name, Glib::ustring& att_value, std::auto_ptr<Glib::Error>);
-#endif
 
   _WRAP_METHOD(bool set_attribute_value(const Glib::ustring& att_name, const Glib::ustring& att_value), gda_meta_store_set_attribute_value, errthrow)
   _WRAP_METHOD(bool schema_add_custom_object(const Glib::ustring& xml_description), gda_meta_store_schema_add_custom_object, errthrow)
diff --git a/libgda/src/quarklist.ccg b/libgda/src/quarklist.ccg
index 8470c5a..3142180 100644
--- a/libgda/src/quarklist.ccg
+++ b/libgda/src/quarklist.ccg
@@ -25,22 +25,18 @@ namespace
 {
 static void quarklist_foreach_callback(gpointer ckey, gpointer cvalue, void* data)
 {
-  #ifdef GLIBMM_EXCEPTIONS_ENABLED
   try
   {
-  #endif //GLIBMM_EXCEPTIONS_ENABLED
     Gnome::Gda::QuarkList::ForeachSlot& slot = *static_cast<Gnome::Gda::QuarkList::ForeachSlot*>(data);
     Glib::ustring key(static_cast<gchar*>(ckey));
     Glib::ustring value(static_cast<gchar*>(cvalue));
 
     slot(key, value);
-  #ifdef GLIBMM_EXCEPTIONS_ENABLED
   }
   catch(...)
   {
     Glib::exception_handlers_invoke();
   }
-  #endif //GLIBMM_EXCEPTIONS_ENABLED
 } 
 }
 
diff --git a/libgda/src/serveroperation.ccg b/libgda/src/serveroperation.ccg
index cdc6b96..968ac0e 100644
--- a/libgda/src/serveroperation.ccg
+++ b/libgda/src/serveroperation.ccg
@@ -30,86 +30,51 @@ namespace Gnome
 namespace Gda
 {
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 Glib::RefPtr<ServerOperation> ServerOperation::prepare_create_database(const Glib::ustring& provider,
                                                                        const Glib::ustring& db_name)
-#else
-Glib::RefPtr<ServerOperation> ServerOperation::prepare_create_database(const Glib::ustring& provider,
-                                                                       const Glib::ustring& db_name,
-                                                                       std::auto_ptr<Glib::Error>& error)
-#endif
 {
   GError* gerror = 0;
   Glib::RefPtr<ServerOperation> op =
     Glib::wrap(gda_server_operation_prepare_create_database(provider.c_str(), db_name.c_str(), &gerror));
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   if(gerror) ::Glib::Error::throw_exception(gerror);
-#else
-  if(gerror) error = ::Glib::Error::throw_exception(gerror);
-#endif // GLIBMM_EXCEPTIONS_ENABLED
 
   return op;
 }
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 Glib::RefPtr<ServerOperation> ServerOperation::prepare_drop_database(const Glib::ustring& provider,
                                                                      const Glib::ustring& db_name)
-#else
-Glib::RefPtr<ServerOperation> ServerOperation::prepare_drop_database(const Glib::ustring& provider,
-                                                                     const Glib::ustring& db_name,
-                                                                     std::auto_ptr<Glib::Error>& error)
-#endif
 {
   GError* gerror = 0;
   Glib::RefPtr<ServerOperation> op =
     Glib::wrap(gda_server_operation_prepare_drop_database(provider.c_str(), db_name.c_str(), &gerror));
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
-  if(gerror) ::Glib::Error::throw_exception(gerror);
-#else
-  if(gerror) error = ::Glib::Error::throw_exception(gerror);
-#endif // GLIBMM_EXCEPTIONS_ENABLED
+  if(gerror)
+    ::Glib::Error::throw_exception(gerror);
 
   return op;
 }
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 bool ServerOperation::perform_drop_database(const Glib::ustring& provider)
-#else
-bool ServerOperation::perform_drop_database(const Glib::ustring& provider,
-                                            std::auto_ptr<Glib::Error>& error)
-#endif
 {
   GError* gerror = 0;
   bool retval =
     static_cast<bool>(gda_server_operation_perform_drop_database(gobj(), provider.c_str(), &gerror));
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
-  if(gerror) ::Glib::Error::throw_exception(gerror);
-#else
-  if(gerror) error = ::Glib::Error::throw_exception(gerror);
-#endif // GLIBMM_EXCEPTIONS_ENABLED
+  if(gerror)
+    ::Glib::Error::throw_exception(gerror);
 
   return retval;
 }
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 bool ServerOperation::perform_create_database(const Glib::ustring& provider)
-#else
-bool ServerOperation::perform_create_database(const Glib::ustring& provider,
-                                              std::auto_ptr<Glib::Error>& error)
-#endif
 {
   GError* gerror = 0;
   bool retval =
     static_cast<bool>(gda_server_operation_perform_create_database(gobj(), provider.c_str(), &gerror));
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
-  if(gerror) ::Glib::Error::throw_exception(gerror);
-#else
-  if(gerror) error = ::Glib::Error::throw_exception(gerror);
-#endif // GLIBMM_EXCEPTIONS_ENABLED
+  if(gerror)
+    ::Glib::Error::throw_exception(gerror);
 
   return retval;
 }
@@ -122,22 +87,15 @@ Value ServerOperation::get_value_at(const Glib::ustring& path) const
   return retval;
 }
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 void ServerOperation::set_value_at_as_value(const Glib::ustring& path, const Glib::ValueBase& value)
-#else
-void ServerOperation::set_value_at_as_value(const Glib::ustring& path, const Glib::ValueBase& value, std::auto_ptr<Glib::Error>& error)
-#endif // GLIBMM_EXCEPTIONS_ENABLED
 {
   gchar* strvalue = gda_value_stringify(value.gobj());
   GError* gerror = 0;
   gda_server_operation_set_value_at(gobj(), strvalue, &gerror, "%s", path.c_str());
   g_free(strvalue);
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
-  if(gerror) ::Glib::Error::throw_exception(gerror);
-#else
-  if(gerror) error = ::Glib::Error::throw_exception(gerror);
-#endif // GLIBMM_EXCEPTIONS_ENABLED
+  if(gerror)
+    ::Glib::Error::throw_exception(gerror);
 }
 
 } /* namespace Gda */
diff --git a/libgda/src/serveroperation.hg b/libgda/src/serveroperation.hg
index 8a635ec..1a4dbbe 100644
--- a/libgda/src/serveroperation.hg
+++ b/libgda/src/serveroperation.hg
@@ -59,49 +59,23 @@ class ServerOperation : public Glib::Object
 
 public:
   // These are from gda-easy but they fit in here best
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   static Glib::RefPtr<ServerOperation> prepare_create_database(const Glib::ustring& provider,
                                                                const Glib::ustring& db_name);
-#else
-  static Glib::RefPtr<ServerOperation> prepare_create_database(const Glib::ustring& provider,
-                                                               const Glib::ustring& db_name,
-                                                               std::auto_ptr<Glib::Error>& error);
-#endif    
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
+   
   static Glib::RefPtr<ServerOperation> prepare_drop_database(const Glib::ustring& provider,
                                                              const Glib::ustring& db_name);
-#else
-  static Glib::RefPtr<ServerOperation> prepare_drop_database(const Glib::ustring& provider,
-                                                             const Glib::ustring& db_name,
-                                                             std::auto_ptr<Glib::Error>& error);
-#endif 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
+
   bool perform_drop_database(const Glib::ustring& provider);
   bool perform_create_database(const Glib::ustring& provider);
-#else
-  bool perform_drop_database(const Glib::ustring& provider,
-                             std::auto_ptr<Glib::Error>& error);
-  bool perform_create_database(const Glib::ustring& provider,
-                               std::auto_ptr<Glib::Error>& error);
-#endif 
 
   // The C version of these take varargs for some reason.
   _WRAP_METHOD_DOCS_ONLY(gda_server_operation_get_value_at)
   Value get_value_at(const Glib::ustring& path_format) const;
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   template <class ValueType>
   void set_value_at(const Glib::ustring& path_format, const ValueType& value);
-#else
-  template <class ValueType>
-  void set_value_at(const Glib::ustring& path_format, const ValueType& value, std::auto_ptr<Glib::Error>& error);
-#endif // GLIBMM_EXCEPTIONS_ENABLED
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   void set_value_at_as_value(const Glib::ustring& path_format, const Glib::ValueBase& value);
-#else
-  void set_value_at_as_value(const Glib::ustring& path_format, const Glib::ValueBase& value, std::auto_ptr<Glib::Error>& error);
-#endif // GLIBMM_EXCEPTIONS_ENABLED
 
   //TODO: See http://bugzilla.gnome.org/show_bug.cgi?id=574742
   _WRAP_METHOD(ServerOperationNodeType get_node_type(const Glib::ustring& path, ServerOperationNodeStatus& status) const, gda_server_operation_get_node_type)
@@ -138,21 +112,12 @@ public:
 };
 
 #ifndef DOXYGEN_SHOULD_SKIP_THIS
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 template <class ValueType> inline
 void ServerOperation::set_value_at(const Glib::ustring& path_format, const ValueType& value)
 {
   Gnome::Gda::Value gdavalue(value);
   this->set_value_at_as_value(path_format.c_str(), gdavalue);
 }
-#else
-template <class ValueType> inline
-void ServerOperation::set_value_at(const Glib::ustring& path_format, const ValueType& value, std::auto_ptr<Glib::Error>& error)
-{
-  Gnome::Gda::Value gdavalue(value);
-  this->set_value_at_as_value(path_format.c_str(), gdavalue, error);
-}
-#endif
 #endif //DOXYGEN_SHOULD_SKIP_THIS
 
 } // namespace Gda
diff --git a/libgda/src/serverprovider.ccg b/libgda/src/serverprovider.ccg
index da3d485..0440751 100644
--- a/libgda/src/serverprovider.ccg
+++ b/libgda/src/serverprovider.ccg
@@ -57,21 +57,13 @@ Value ServerProvider::string_to_value(const Glib::RefPtr<Connection>& cnc,
   return retval;
 }
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 Glib::RefPtr<ServerOperation> ServerProvider::create_operation(const Glib::RefPtr<Connection>& cnc, ServerOperationType type)
-#else
-Glib::RefPtr<ServerOperation> ServerProvider::create_operation(const Glib::RefPtr<Connection>& cnc, ServerOperationType type, std::auto_ptr<Glib::Error>& error)
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 {
   GError* gerror = 0;
   Glib::RefPtr<ServerOperation> retvalue = Glib::wrap(gda_server_provider_create_operation(gobj(), Glib::unwrap(cnc), ((GdaServerOperationType)(type)), 0, &(gerror)));
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
+
   if(gerror)
     ::Glib::Error::throw_exception(gerror);
-#else
-  if(gerror)
-    error = ::Glib::Error::throw_exception(gerror);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 
   return retvalue;
 }
diff --git a/libgda/src/serverprovider.hg b/libgda/src/serverprovider.hg
index a1a0238..b35d0a3 100644
--- a/libgda/src/serverprovider.hg
+++ b/libgda/src/serverprovider.hg
@@ -78,11 +78,7 @@ public:
    * @return A new Gda::ServerOperation object, or <tt>0</tt> in the provider does not support the @a type type
    * of operation or if an error occurred.
    */
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   Glib::RefPtr<ServerOperation> create_operation(const Glib::RefPtr<Connection>& cnc, ServerOperationType type);
-#else
-  Glib::RefPtr<ServerOperation> create_operation(const Glib::RefPtr<Connection>& cnc, ServerOperationType type, std::auto_ptr<Glib::Error>& error);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 
 
   _WRAP_METHOD(Glib::ustring render_operation(const Glib::RefPtr<Connection>& cnc, const Glib::RefPtr<ServerOperation>& op), gda_server_provider_render_operation, errthrow)
diff --git a/libgda/src/set.ccg b/libgda/src/set.ccg
index d59da7e..3849314 100644
--- a/libgda/src/set.ccg
+++ b/libgda/src/set.ccg
@@ -35,18 +35,10 @@ bool Set::set_holder_value(const Glib::ustring& id, T value)
   return gda_set_set_holder_value (gobj(), id.c_str(), value);
 }
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 void Set::add_holder_as_value(const Glib::ustring& id, const Gda::Value& value)
-#else
-void Set::add_holder_as_value(const Glib::ustring& id, const Gda::Value& value, std::auto_ptr<Glib::Error>& error)
-#endif
 {
   Glib::RefPtr<Holder> holder = Holder::create(value.get_value_type(), id);
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   holder->set_value(value);
-#else
-  holder->set_value(value, error);
-#endif
   add_holder(holder);
 }
 
diff --git a/libgda/src/set.hg b/libgda/src/set.hg
index 923c968..59f03cb 100644
--- a/libgda/src/set.hg
+++ b/libgda/src/set.hg
@@ -74,11 +74,8 @@ public:
    * @param id Name of the holder
    * @param value Value of the holder
    */
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   void add_holder_as_value(const Glib::ustring& id, const Gda::Value& value);
-#else
-  void add_holder_as_value(const Glib::ustring& id, const Gda::Value& value, std::auto_ptr<Glib::Error>& error);
-#endif
+
   /** Add a holder
    * 
    * Convenience method to add a holder with value
@@ -131,12 +128,7 @@ void Set::add_holder(const Glib::ustring& id, const ValueType& value)
 {
   Gnome::Gda::Value gdavalue(value);
   Glib::RefPtr<Holder> holder = Holder::create(gdavalue.get_value_type(), id);
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   holder->set_value(value);
-#else
-  std::auto_ptr<Glib::Error> error;
-  holder->set_value(value, error);
-#endif
   this->add_holder(holder);
 }
 #endif //DOXYGEN_SHOULD_SKIP_THIS
diff --git a/libgda/src/sqlparser.ccg b/libgda/src/sqlparser.ccg
index 55e91a4..831c2b6 100644
--- a/libgda/src/sqlparser.ccg
+++ b/libgda/src/sqlparser.ccg
@@ -29,22 +29,13 @@ namespace Gnome
 namespace Gda
 {
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 Glib::RefPtr<Statement> SqlParser::parse_string(const Glib::ustring& sql, Glib::ustring& remain)
-#else
-Glib::RefPtr<Statement> SqlParser::parse_string(const Glib::ustring& sql, Glib::ustring& remain, std::auto_ptr<Glib::Error>& error)
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 {
   GError* gerror = 0;
   const gchar* c_remain = 0;
   Glib::RefPtr<Statement> retvalue = Glib::wrap(gda_sql_parser_parse_string(gobj(), sql.c_str(), &c_remain, &(gerror)));
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   if(gerror)
     ::Glib::Error::throw_exception(gerror);
-#else
-  if(gerror)
-    error = ::Glib::Error::throw_exception(gerror);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 
   if (c_remain)
   {
@@ -54,41 +45,22 @@ Glib::RefPtr<Statement> SqlParser::parse_string(const Glib::ustring& sql, Glib::
   return retvalue;
 }
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 Glib::RefPtr<Statement> SqlParser::parse_string(const Glib::ustring& sql)
-#else
-Glib::RefPtr<Statement> SqlParser::parse_string(const Glib::ustring& sql, std::auto_ptr<Glib::Error>& error)
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 {
   GError* gerror = 0;
   Glib::RefPtr<Statement> retvalue = Glib::wrap(gda_sql_parser_parse_string(gobj(), sql.c_str(), 0, &(gerror)));
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   if(gerror)
     ::Glib::Error::throw_exception(gerror);
-#else
-  if(gerror)
-    error = ::Glib::Error::throw_exception(gerror);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
-
   return retvalue;
 }
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 Glib::RefPtr<Batch> SqlParser::parse_string_as_batch(const Glib::ustring& sql, Glib::ustring& remain)
-#else
-Glib::RefPtr<Batch> SqlParser::parse_string_as_batch(const Glib::ustring& sql, Glib::ustring& remain, std::auto_ptr<Glib::Error>& error)
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 {
   GError* gerror = 0;
   const gchar* c_remain = 0;
   Glib::RefPtr<Batch> retvalue = Glib::wrap(gda_sql_parser_parse_string_as_batch(gobj(), sql.c_str(), &c_remain, &(gerror)));
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   if(gerror)
     ::Glib::Error::throw_exception(gerror);
-#else
-  if(gerror)
-    error = ::Glib::Error::throw_exception(gerror);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 
   if (c_remain)
   {
@@ -98,21 +70,12 @@ Glib::RefPtr<Batch> SqlParser::parse_string_as_batch(const Glib::ustring& sql, G
   return retvalue;
 }
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 Glib::RefPtr<Batch> SqlParser::parse_string_as_batch(const Glib::ustring& sql)
-#else
-Glib::RefPtr<Batch> SqlParser::parse_string_as_batch(const Glib::ustring& sql, std::auto_ptr<Glib::Error>& error)
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 {
   GError* gerror = 0;
   Glib::RefPtr<Batch> retvalue = Glib::wrap(gda_sql_parser_parse_string_as_batch(gobj(), sql.c_str(), 0, &(gerror)));
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   if(gerror)
     ::Glib::Error::throw_exception(gerror);
-#else
-  if(gerror)
-    error = ::Glib::Error::throw_exception(gerror);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 
   return retvalue;
 }
diff --git a/libgda/src/sqlparser.hg b/libgda/src/sqlparser.hg
index 3960f7f..adbf0dc 100644
--- a/libgda/src/sqlparser.hg
+++ b/libgda/src/sqlparser.hg
@@ -85,28 +85,14 @@ public:
   
   //TODO: Should these be const?
   _WRAP_METHOD_DOCS_ONLY(gda_sql_parser_parse_string)
-  #ifdef GLIBMM_EXCEPTIONS_ENABLED
   Glib::RefPtr<Statement> parse_string(const Glib::ustring& sql, Glib::ustring& remain);
-  #else
-  Glib::RefPtr<Statement> parse_string(const Glib::ustring& sql, Glib::ustring& remain, std::auto_ptr<Glib::Error>& error);
-  #endif //GLIBMM_EXCEPTIONS_ENABLED
-  #ifdef GLIBMM_EXCEPTIONS_ENABLED
+
   Glib::RefPtr<Statement> parse_string(const Glib::ustring& sql);
-  #else
-  Glib::RefPtr<Statement> parse_string(const Glib::ustring& sql, std::auto_ptr<Glib::Error>& error);
-  #endif //GLIBMM_EXCEPTIONS_ENABLED
     
   _WRAP_METHOD_DOCS_ONLY(gda_sql_parser_parse_string_as_batch)
-  #ifdef GLIBMM_EXCEPTIONS_ENABLED
   Glib::RefPtr<Batch> parse_string_as_batch(const Glib::ustring& sql, Glib::ustring& remain);
-  #else
-  Glib::RefPtr<Batch> parse_string_as_batch(const Glib::ustring& sql, Glib::ustring& remain, std::auto_ptr<Glib::Error>& error);
-  #endif //GLIBMM_EXCEPTIONS_ENABLED
-  #ifdef GLIBMM_EXCEPTIONS_ENABLED
+
   Glib::RefPtr<Batch> parse_string_as_batch(const Glib::ustring& sql);
-  #else
-  Glib::RefPtr<Batch> parse_string_as_batch(const Glib::ustring& sql, std::auto_ptr<Glib::Error>& error);
-  #endif //GLIBMM_EXCEPTIONS_ENABLED
   
   _WRAP_METHOD(Glib::RefPtr<Batch> parse_file_as_batch(const std::string& filename), gda_sql_parser_parse_file_as_batch, errthrow)
 
diff --git a/libgda/src/statement.ccg b/libgda/src/statement.ccg
index 99a72bd..ababd46 100644
--- a/libgda/src/statement.ccg
+++ b/libgda/src/statement.ccg
@@ -31,23 +31,14 @@ namespace Gnome
 namespace Gda
 {
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 bool Statement::get_parameters(Glib::RefPtr<Set>& params)
-#else
-bool Statement::get_parameters(Glib::RefPtr<Set>& params, std::auto_ptr<Glib::Error>& error)
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 {
   GError* gerror = 0;
   GdaSet* set = 0;
   const bool retval = gda_statement_get_parameters(gobj(), &set, &gerror);
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   if(gerror)
     ::Glib::Error::throw_exception(gerror);
-#else
-  if(gerror)
-    error = ::Glib::Error::throw_exception(gerror);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 
   if(set)
   {
@@ -58,68 +49,42 @@ bool Statement::get_parameters(Glib::RefPtr<Set>& params, std::auto_ptr<Glib::Er
   return retval;
 }
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 Glib::ustring Statement::to_sql() const
-#else
-Glib::ustring Statement::to_sql(std::auto_ptr<Glib::Error>& error) const
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 {
   GError* gerror = 0;
   const Glib::ustring retval = 
     Glib::convert_return_gchar_ptr_to_ustring(
       gda_statement_to_sql(const_cast<GdaStatement*>(gobj()), 0, &gerror));
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
+
   if(gerror)
     ::Glib::Error::throw_exception(gerror);
-#else
-  if(gerror)
-    error = ::Glib::Error::throw_exception(gerror);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 
   return retval;
 }
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 Glib::ustring Statement::to_sql(const Glib::RefPtr<const Set>& params) const
-#else
-Glib::ustring Statement::to_sql(const Glib::RefPtr<const Set>& params, std::auto_ptr<Glib::Error>& error) const
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 {
   GError* gerror = 0;
   const Glib::ustring retval = 
     Glib::convert_return_gchar_ptr_to_ustring(
       gda_statement_to_sql(const_cast<GdaStatement*>(gobj()), const_cast<GdaSet*>(Glib::unwrap(params)), &gerror));
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   if(gerror)
     ::Glib::Error::throw_exception(gerror);
-#else
-  if(gerror)
-    error = ::Glib::Error::throw_exception(gerror);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
   return retval;
 }
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 Glib::ustring Statement::to_sql(const Glib::RefPtr<Connection>& cnc, const Glib::RefPtr<const Set>& params, 
                               StatementSqlFlag flags, const HolderVector&) const
-#else
-Glib::ustring Statement::to_sql(const Glib::RefPtr<Connection>& cnc, const Glib::RefPtr<const Set>& params, 
-                              StatementSqlFlag flags, const HolderVector&,
-                              std::auto_ptr<Glib::Error>& error) const
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 {
   GError* gerror = 0;
   GSList* list = 0;
   const Glib::ustring retval = 
     Glib::convert_return_gchar_ptr_to_ustring(
       gda_statement_to_sql_extended(const_cast<GdaStatement*>(gobj()), Glib::unwrap(cnc), const_cast<GdaSet*>(Glib::unwrap(params)), (GdaStatementSqlFlag) flags, &list, &gerror));
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
+
   if(gerror)
     ::Glib::Error::throw_exception(gerror);
-#else
-  if(gerror)
-    error = ::Glib::Error::throw_exception(gerror);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
+
   if (list)
   {
     // FIXME: Set params_used somehow
diff --git a/libgda/src/statement.hg b/libgda/src/statement.hg
index ba71a47..4f3bf01 100644
--- a/libgda/src/statement.hg
+++ b/libgda/src/statement.hg
@@ -75,40 +75,22 @@ public:
 
   //TODO: Should this be const? Probably not, because the caller could change Set. murrayc.
   _WRAP_METHOD_DOCS_ONLY(gda_statement_get_parameters)
-  #ifdef GLIBMM_EXCEPTIONS_ENABLED
   bool get_parameters(Glib::RefPtr<Set>& out_params);
-  #else
-  bool get_parameters(Glib::RefPtr<Set>& out_params, std::auto_ptr<Glib::Error>& error);
-  #endif //GLIBMM_EXCEPTIONS_ENABLED
   _IGNORE(gda_statement_get_parameters)
 
   //TODO: Documentation:
-  #ifdef GLIBMM_EXCEPTIONS_ENABLED
   Glib::ustring to_sql() const;
-  #else
-  Glib::ustring to_sql(std::auto_ptr<Glib::Error>& error) const;
-  #endif //GLIBMM_EXCEPTIONS_ENABLED
 
   //TODO: Documentation:
-  #ifdef GLIBMM_EXCEPTIONS_ENABLED
   Glib::ustring to_sql(const Glib::RefPtr<const Set>& params) const;
-  #else
-  Glib::ustring to_sql(const Glib::RefPtr<const Set>& params, std::auto_ptr<Glib::Error>& error) const;
-  #endif //GLIBMM_EXCEPTIONS_ENABLED
   _IGNORE(gda_statement_to_sql, gda_statement_to_sql_real)
 
   typedef std::vector< const Glib::RefPtr<Holder> > HolderVector;
 
   //TODO: Add an overload without the params?
   _WRAP_METHOD_DOCS_ONLY(gda_statement_to_sql_extended)
-  #ifdef GLIBMM_EXCEPTIONS_ENABLED
   Glib::ustring to_sql(const Glib::RefPtr<Connection>& cnc, const Glib::RefPtr<const Set>& params,
                                 StatementSqlFlag flags, const HolderVector& params_used) const;
-  #else
-  Glib::ustring to_sql(const Glib::RefPtr<Connection>& cnc, const Glib::RefPtr<const Set>& params,
-                                StatementSqlFlag flags, const HolderVector& params_used,
-                                std::auto_ptr<Glib::Error>& error) const;
-  #endif //GLIBMM_EXCEPTIONS_ENABLED
 
   _WRAP_METHOD(SqlStatementType get_statement_type() const, gda_statement_get_statement_type)
   _WRAP_METHOD(bool is_useless() const, gda_statement_is_useless)
diff --git a/libgda/src/xatransaction.ccg b/libgda/src/xatransaction.ccg
index 7ca32e5..05706d5 100644
--- a/libgda/src/xatransaction.ccg
+++ b/libgda/src/xatransaction.ccg
@@ -29,44 +29,26 @@ namespace Gda
 
 typedef std::vector< Glib::RefPtr<Connection> > ConnectionVector;
   
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 bool XaTransaction::commit(ConnectionVector& cncs_to_recover)
-#else
-bool XaTransaction::commit(ConnectionVector& cncs_to_recover, std::auto_ptr<Glib::Error>& error)
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 {
   GError* gerror = 0;
   GSList* cncs = NULL;
   const bool retvalue = gda_xa_transaction_commit (gobj(), &cncs, &gerror);
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   if(gerror)
     ::Glib::Error::throw_exception(gerror);
-#else
-  if(gerror)
-    error = ::Glib::Error::throw_exception(gerror);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 
   cncs_to_recover = Glib::SListHandler< Glib::RefPtr<const Connection> >::slist_to_vector(cncs, Glib::OWNERSHIP_SHALLOW);
   
   return retvalue;
 }
 
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
 bool XaTransaction::commit_recovered(ConnectionVector& cncs_to_recover)
-#else
-bool XaTransaction::commit_recovered(ConnectionVector& cncs_to_recover, std::auto_ptr<Glib::Error>& error)
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 {
   GError* gerror = 0;
   GSList* cncs = NULL;
   bool retvalue = gda_xa_transaction_commit_recovered (gobj(), &cncs, &gerror);
-#ifdef GLIBMM_EXCEPTIONS_ENABLED
   if(gerror)
     ::Glib::Error::throw_exception(gerror);
-#else
-  if(gerror)
-    error = ::Glib::Error::throw_exception(gerror);
-#endif //GLIBMM_EXCEPTIONS_ENABLED
 
    cncs_to_recover = Glib::SListHandler< Glib::RefPtr<const Connection> >::slist_to_vector(cncs, Glib::OWNERSHIP_SHALLOW);
   
diff --git a/libgda/src/xatransaction.hg b/libgda/src/xatransaction.hg
index 5cb5c56..0a7ecdb 100644
--- a/libgda/src/xatransaction.hg
+++ b/libgda/src/xatransaction.hg
@@ -52,18 +52,10 @@ public:
   typedef std::vector<Glib::RefPtr<const Connection> > ConnectionVector;
 
   _WRAP_METHOD_DOCS_ONLY(gda_xa_transaction_commit)  
-  #ifdef GLIBMM_EXCEPTIONS_ENABLED
   bool commit(ConnectionVector& cnc_to_recover);
-  #else
-  bool commit(ConnectionVector& cnc_to_recover, std::auto_ptr<Glib::Error>& error);
-  #endif //GLIBMM_EXCEPTIONS_ENABLED
 
   _WRAP_METHOD_DOCS_ONLY (gda_xa_transaction_commit_recovered)  
-  #ifdef GLIBMM_EXCEPTIONS_ENABLED
   bool commit_recovered(ConnectionVector& cnc_to_recover);
-  #else
-  bool commit_recovered(ConnectionVector& cnc_to_recover, std::auto_ptr<Glib::Error>& error);
-  #endif //GLIBMM_EXCEPTIONS_ENABLED
   
   _WRAP_PROPERTY("transaction-id", Glib::ustring)
   _WRAP_PROPERTY("format-id", guint)



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]