summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ACE/ChangeLog12
-rw-r--r--ACE/ace/os_include/os_stropts.h2
-rw-r--r--ACE/tests/Compiler_Features_32_Test.cpp18
3 files changed, 30 insertions, 2 deletions
diff --git a/ACE/ChangeLog b/ACE/ChangeLog
index 6dee9eb628d..d06d98e715f 100644
--- a/ACE/ChangeLog
+++ b/ACE/ChangeLog
@@ -1,3 +1,15 @@
+Thu Sep 4 08:57:02 UTC 2014 Johnny Willemsen <jwillemsen@remedy.nl>
+
+ * ace/os_include/os_stropts.h:
+ Give struct strrecvfd a dummy member, empty structs have
+ undefined behavior and trigger a huge amount of warnings
+ with clang. This also fixes bugzilla 4150, thanks to
+ Yogesh Sharma <Yogesh dot Sharma at saabusa dot com> for
+ reporting this.
+
+ * tests/Compiler_Features_32_Test.cpp:
+ Extended this unit test and add some external references
+
Fri Aug 29 11:32:31 UTC 2014 Johnny Willemsen <jwillemsen@remedy.nl>
* ace/Event_Handler.h:
diff --git a/ACE/ace/os_include/os_stropts.h b/ACE/ace/os_include/os_stropts.h
index b840c47b2e6..4c6eeb27ef5 100644
--- a/ACE/ace/os_include/os_stropts.h
+++ b/ACE/ace/os_include/os_stropts.h
@@ -78,7 +78,7 @@ extern "C"
#endif /* __cplusplus */
#if defined (ACE_LACKS_STRRECVFD)
- struct strrecvfd {};
+ struct strrecvfd { int : 0; };
#endif /* ACE_LACKS_STRRECVFD */
# if !defined (SIOCGIFBRDADDR)
diff --git a/ACE/tests/Compiler_Features_32_Test.cpp b/ACE/tests/Compiler_Features_32_Test.cpp
index a66b6713880..96b231b379b 100644
--- a/ACE/tests/Compiler_Features_32_Test.cpp
+++ b/ACE/tests/Compiler_Features_32_Test.cpp
@@ -2,7 +2,14 @@
/**
* This program checks if the compiler doesn't have a certain bug
- * that we encountered when testing C++11 features
+ * that we encountered when testing C++11 features.
+ *
+ * This test validates whether a alias can be used to explicitly
+ * call a destructor, which is related to DR244 (see
+ * http://wg21.cmeerw.net/cwg/issue244)
+ *
+ * This is fixed May 2014 in clang, see
+ * http://llvm.org/viewvc/llvm-project?view=revision&revision=209319
*/
#include "test_config.h"
@@ -39,6 +46,15 @@ void A::clear ()
this->u_.string_member_.std::string::~string ();
}
+struct B {
+ struct u_type_ {
+ std::string m;
+ } u_;
+ void clear() {
+ u_.m.std::string::~string();
+ }
+};
+
int
run_main (int, ACE_TCHAR *[])
{