summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2016-12-15 08:54:08 +0100
committerStephan Bergmann <sbergman@redhat.com>2016-12-15 11:24:53 +0000
commit721116c7ade10d76e3ed6832e3988c91427ba431 (patch)
tree5355413a5924885b33bb28b200d20643dee62655
parentef4b9032de55e6b1b182e4ead1bbe6e590df296e (diff)
Phase out support for HAVE_BROKEN_STATIC_INITIALIZER_LIST
...I'm pondering a change that would make that a hard requirement, and from the comment in configure.ac it looks like only old Clang < 3.4 were affected. Change-Id: I8ef64f759fed1a45d88f94d0e8a60839ad10b263 Reviewed-on: https://gerrit.libreoffice.org/32029 Reviewed-by: Stephan Bergmann <sbergman@redhat.com> Tested-by: Stephan Bergmann <sbergman@redhat.com>
-rw-r--r--config_host/config_global.h.in1
-rw-r--r--configure.ac2
-rw-r--r--oox/source/export/shapes.cxx10
-rw-r--r--xmlsecurity/source/helper/ooxmlsecexporter.cxx10
4 files changed, 5 insertions, 18 deletions
diff --git a/config_host/config_global.h.in b/config_host/config_global.h.in
index 1e68f4a8a4a0..5bb9992dd2f8 100644
--- a/config_host/config_global.h.in
+++ b/config_host/config_global.h.in
@@ -22,7 +22,6 @@ Any change in this header will cause a rebuild of almost everything.
#define HAVE_GCC_DEPRECATED_MESSAGE 0
#define HAVE_THREADSAFE_STATICS 0
#define HAVE_BROKEN_CONST_ITERATORS 0
-#define HAVE_BROKEN_STATIC_INITIALIZER_LIST 0
#define HAVE_SYSLOG_H 0
/* Compiler supports __attribute__((warn_unused)). */
#define HAVE_GCC_ATTRIBUTE_WARN_UNUSED 0
diff --git a/configure.ac b/configure.ac
index 9c55fe8d2f29..eb2dd83a0dfc 100644
--- a/configure.ac
+++ b/configure.ac
@@ -12573,7 +12573,7 @@ LIBS=$save_LIBS
CXXFLAGS=$save_CXXFLAGS
AC_MSG_RESULT([$broken])
if test "$broken" = yes; then
- AC_DEFINE([HAVE_BROKEN_STATIC_INITIALIZER_LIST])
+ AC_MSG_ERROR([working support for static initializer_list needed])
fi
diff --git a/oox/source/export/shapes.cxx b/oox/source/export/shapes.cxx
index 6e6fc5e0bfbd..cd139b8496b5 100644
--- a/oox/source/export/shapes.cxx
+++ b/oox/source/export/shapes.cxx
@@ -532,10 +532,7 @@ ShapeExport& ShapeExport::WriteGroupShape(const uno::Reference<drawing::XShape>&
static bool lcl_IsOnBlacklist(OUString& rShapeType)
{
-#if !HAVE_BROKEN_STATIC_INITIALIZER_LIST
- static
-#endif
- const std::initializer_list<OUStringLiteral> vBlacklist = {
+ static const std::initializer_list<OUStringLiteral> vBlacklist = {
OUStringLiteral("block-arc"),
OUStringLiteral("rectangle"),
OUStringLiteral("ellipse"),
@@ -601,10 +598,7 @@ static bool lcl_IsOnBlacklist(OUString& rShapeType)
static bool lcl_IsOnWhitelist(OUString& rShapeType)
{
-#if !HAVE_BROKEN_STATIC_INITIALIZER_LIST
- static
-#endif
- const std::initializer_list<OUStringLiteral> vWhitelist = {
+ static const std::initializer_list<OUStringLiteral> vWhitelist = {
OUStringLiteral("forbidden"),
OUStringLiteral("heart"),
OUStringLiteral("puzzle")
diff --git a/xmlsecurity/source/helper/ooxmlsecexporter.cxx b/xmlsecurity/source/helper/ooxmlsecexporter.cxx
index 34843a5cdae0..df35dee8dc27 100644
--- a/xmlsecurity/source/helper/ooxmlsecexporter.cxx
+++ b/xmlsecurity/source/helper/ooxmlsecexporter.cxx
@@ -73,10 +73,7 @@ struct OOXMLSecExporter::Impl
bool OOXMLSecExporter::Impl::isOOXMLBlacklist(const OUString& rStreamName)
{
-#if !HAVE_BROKEN_STATIC_INITIALIZER_LIST
- static
-#endif
- const std::initializer_list<OUStringLiteral> vBlacklist =
+ static const std::initializer_list<OUStringLiteral> vBlacklist =
{
OUStringLiteral("/%5BContent_Types%5D.xml"),
OUStringLiteral("/docProps/app.xml"),
@@ -93,10 +90,7 @@ bool OOXMLSecExporter::Impl::isOOXMLBlacklist(const OUString& rStreamName)
bool OOXMLSecExporter::Impl::isOOXMLRelationBlacklist(const OUString& rRelationName)
{
-#if !HAVE_BROKEN_STATIC_INITIALIZER_LIST
- static
-#endif
- const std::initializer_list<OUStringLiteral> vBlacklist =
+ static const std::initializer_list<OUStringLiteral> vBlacklist =
{
OUStringLiteral("http://schemas.openxmlformats.org/officeDocument/2006/relationships/extended-properties"),
OUStringLiteral("http://schemas.openxmlformats.org/package/2006/relationships/metadata/core-properties"),