Revert "Fix _STLP_USE_EXCEPTIONS"
This reverts commit 91b1d7f8d7847f7b032a8a289b2bb5911c731fba.
o related-to-bug: 7966335
Change-Id: I2c091bf1093aa0f568d6aee5926ced404a90f1ab
diff --git a/src/ios.cpp b/src/ios.cpp
index 7bbfecd..cb35e0b 100644
--- a/src/ios.cpp
+++ b/src/ios.cpp
@@ -30,7 +30,6 @@
//----------------------------------------------------------------------
// ios_base members
-#ifdef _STLP_USE_EXCEPTIONS
// class ios_base::failure, a subclass of exception. It's used solely
// for reporting errors.
@@ -39,7 +38,6 @@
{}
ios_base::failure::~failure() _STLP_NOTHROW_INHERENTLY {}
-#endif
#if !defined (_STLP_STATIC_CONST_INIT_BUG) && !defined (_STLP_NO_STATIC_CONST_DEFINITION)
// Definitions of ios_base's formatting flags.
diff --git a/stlport/stl/_exception.h b/stlport/stl/_exception.h
index 1dd7127..a0bf4ad 100644
--- a/stlport/stl/_exception.h
+++ b/stlport/stl/_exception.h
@@ -185,11 +185,8 @@
# endif
};
-#ifdef _STLP_USE_EXCEPTIONS
// forward declaration
class __Named_exception;
-#endif
-
_STLP_END_NAMESPACE
#endif
diff --git a/stlport/stl/_ios_base.h b/stlport/stl/_ios_base.h
index 8c7a65b..c9e10ad 100644
--- a/stlport/stl/_ios_base.h
+++ b/stlport/stl/_ios_base.h
@@ -48,13 +48,11 @@
class _STLP_CLASS_DECLSPEC ios_base {
public:
-# ifdef _STLP_USE_EXCEPTIONS
class _STLP_CLASS_DECLSPEC failure : public __Named_exception {
public:
explicit failure(const string&);
virtual ~failure() _STLP_NOTHROW_INHERENTLY;
};
-#endif
typedef int fmtflags;
typedef int iostate;
diff --git a/stlport/stl/_stdexcept.h b/stlport/stl/_stdexcept.h
index ac24160..dba5d01 100644
--- a/stlport/stl/_stdexcept.h
+++ b/stlport/stl/_stdexcept.h
@@ -25,7 +25,7 @@
#if !defined (_STLP_USE_NATIVE_STDEXCEPT) || defined (_STLP_USE_OWN_NAMESPACE)
-# if defined(_STLP_USE_EXCEPTIONS)
+# if defined(_STLP_USE_EXCEPTIONS) || 1
_STLP_BEGIN_NAMESPACE
@@ -103,7 +103,7 @@
_STLP_END_NAMESPACE
-# endif /* _STLP_USE_EXCEPTIONS */
+# endif
#endif
#endif /* _STLP_INTERNAL_STDEXCEPT */
diff --git a/stlport/stl/_stdexcept_base.h b/stlport/stl/_stdexcept_base.h
index bac2c17..993f2e9 100644
--- a/stlport/stl/_stdexcept_base.h
+++ b/stlport/stl/_stdexcept_base.h
@@ -25,7 +25,9 @@
# include <stl/_exception.h>
# endif
-# if defined(_STLP_USE_EXCEPTIONS)
+# if defined(_STLP_USE_EXCEPTIONS) || 1
+/* TODO: use same conditions on fwd def of __Named_exception
+ in _exception.h and its use in _ios_base.h */
# ifndef _STLP_INTERNAL_CSTRING
# include <stl/_cstring.h>
@@ -91,7 +93,7 @@
_STLP_END_NAMESPACE
-# endif /* _STLP_USE_EXCEPTIONS */
-#endif
+# endif /* Not o32, and no exceptions */
+#endif /* _STLP_STDEXCEPT_SEEN */
#endif /* _STLP_INTERNAL_STDEXCEPT_BASE */