Author: sebor
Date: Thu Jul 5 14:28:06 2007
New Revision: 553643
URL: http://svn.apache.org/viewvc?view=rev&rev=553643
Log:
2007-07-05 Martin Sebor <[EMAIL PROTECTED]>
* stdexcept (range_error, domain_error, runtime_error): Declared
virtual destructors instead of relying on the compiler to generate
them automatically to avoid generating the class vtable in every
translation unit that uses each of the classes.
* range_error.cpp: Defined range_error destructor.
* domain_error.cpp: Defined domain_error destructor.
* runtime_error.cpp: Defined runtime_error destructor.
Added:
incubator/stdcxx/trunk/src/domain_error.cpp (with props)
incubator/stdcxx/trunk/src/range_error.cpp (with props)
incubator/stdcxx/trunk/src/runtime_error.cpp (with props)
Modified:
incubator/stdcxx/trunk/include/stdexcept
Modified: incubator/stdcxx/trunk/include/stdexcept
URL:
http://svn.apache.org/viewvc/incubator/stdcxx/trunk/include/stdexcept?view=diff&rev=553643&r1=553642&r2=553643
==============================================================================
--- incubator/stdcxx/trunk/include/stdexcept (original)
+++ incubator/stdcxx/trunk/include/stdexcept Thu Jul 5 14:28:06 2007
@@ -65,6 +65,8 @@
// extension
_EXPLICIT domain_error (const char *__s = 0)
: logic_error (__s) { }
+
+ virtual ~domain_error () _THROWS (());
};
@@ -113,6 +115,8 @@
// extension
_EXPLICIT runtime_error (const char *__s = 0)
: _RW::__rw_exception (__s) { }
+
+ virtual ~runtime_error () _THROWS (());
};
@@ -125,6 +129,8 @@
// extension
_EXPLICIT range_error (const char *__s = 0)
: runtime_error (__s) { }
+
+ virtual ~range_error () _THROWS (());
};
Added: incubator/stdcxx/trunk/src/domain_error.cpp
URL:
http://svn.apache.org/viewvc/incubator/stdcxx/trunk/src/domain_error.cpp?view=auto&rev=553643
==============================================================================
--- incubator/stdcxx/trunk/src/domain_error.cpp (added)
+++ incubator/stdcxx/trunk/src/domain_error.cpp Thu Jul 5 14:28:06 2007
@@ -0,0 +1,43 @@
+/***************************************************************************
+ *
+ * domain_error.cpp - definitions of class domain_error members
+ *
+ * $Id$
+ *
+ ***************************************************************************
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed
+ * with this work for additional information regarding copyright
+ * ownership. The ASF licenses this file to you under the Apache
+ * License, Version 2.0 (the "License"); you may not use this file
+ * except in compliance with the License. You may obtain a copy of
+ * the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ * implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ *
+ **************************************************************************/
+
+#define _RWSTD_LIB_SRC
+
+#include <stdexcept>
+#include <rw/_defs.h>
+
+
+_RWSTD_NAMESPACE (std) {
+
+// outlined to avoid generating a vtable in each translation unit
+// that uses the class
+/* virtual */ domain_error::
+~domain_error () _THROWS (())
+{
+ // no-op
+}
+
+} // namespace std
Propchange: incubator/stdcxx/trunk/src/domain_error.cpp
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: incubator/stdcxx/trunk/src/domain_error.cpp
------------------------------------------------------------------------------
svn:keywords = Id
Added: incubator/stdcxx/trunk/src/range_error.cpp
URL:
http://svn.apache.org/viewvc/incubator/stdcxx/trunk/src/range_error.cpp?view=auto&rev=553643
==============================================================================
--- incubator/stdcxx/trunk/src/range_error.cpp (added)
+++ incubator/stdcxx/trunk/src/range_error.cpp Thu Jul 5 14:28:06 2007
@@ -0,0 +1,43 @@
+/***************************************************************************
+ *
+ * range_error.cpp - definitions of class range_error members
+ *
+ * $Id$
+ *
+ ***************************************************************************
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed
+ * with this work for additional information regarding copyright
+ * ownership. The ASF licenses this file to you under the Apache
+ * License, Version 2.0 (the "License"); you may not use this file
+ * except in compliance with the License. You may obtain a copy of
+ * the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ * implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ *
+ **************************************************************************/
+
+#define _RWSTD_LIB_SRC
+
+#include <stdexcept>
+#include <rw/_defs.h>
+
+
+_RWSTD_NAMESPACE (std) {
+
+// outlined to avoid generating a vtable in each translation unit
+// that uses the class
+/* virtual */ range_error::
+~range_error () _THROWS (())
+{
+ // no-op
+}
+
+} // namespace std
Propchange: incubator/stdcxx/trunk/src/range_error.cpp
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: incubator/stdcxx/trunk/src/range_error.cpp
------------------------------------------------------------------------------
svn:keywords = Id
Added: incubator/stdcxx/trunk/src/runtime_error.cpp
URL:
http://svn.apache.org/viewvc/incubator/stdcxx/trunk/src/runtime_error.cpp?view=auto&rev=553643
==============================================================================
--- incubator/stdcxx/trunk/src/runtime_error.cpp (added)
+++ incubator/stdcxx/trunk/src/runtime_error.cpp Thu Jul 5 14:28:06 2007
@@ -0,0 +1,43 @@
+/***************************************************************************
+ *
+ * runtime_error.cpp - definitions of class runtime_error members
+ *
+ * $Id$
+ *
+ ***************************************************************************
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed
+ * with this work for additional information regarding copyright
+ * ownership. The ASF licenses this file to you under the Apache
+ * License, Version 2.0 (the "License"); you may not use this file
+ * except in compliance with the License. You may obtain a copy of
+ * the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ * implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ *
+ **************************************************************************/
+
+#define _RWSTD_LIB_SRC
+
+#include <stdexcept>
+#include <rw/_defs.h>
+
+
+_RWSTD_NAMESPACE (std) {
+
+// outlined to avoid generating a vtable in each translation unit
+// that uses the class
+/* virtual */ runtime_error::
+~runtime_error () _THROWS (())
+{
+ // no-op
+}
+
+} // namespace std
Propchange: incubator/stdcxx/trunk/src/runtime_error.cpp
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: incubator/stdcxx/trunk/src/runtime_error.cpp
------------------------------------------------------------------------------
svn:keywords = Id