[Libreoffice-commits] core.git: external/boost mysqlc/source
Stephan Bergmann
sbergman at redhat.com
Tue May 10 13:26:59 UTC 2016
external/boost/UnpackedTarball_boost.mk | 2 ++
external/boost/fallthrough.patch.0 | 26 ++++++++++++++++++++++++++
mysqlc/source/mysqlc_preparedstatement.cxx | 4 ++--
3 files changed, 30 insertions(+), 2 deletions(-)
New commits:
commit fcbd824f1b45ae7242cd7b86e98b5d947441759e
Author: Stephan Bergmann <sbergman at redhat.com>
Date: Tue May 10 15:25:12 2016 +0200
Use BOOST_FALLTHROUGH in external code
...in preparation of enabling Clang's -Wimplicit-fallthrough
Change-Id: If64f9b18591b3cd2528adc6c2d6011d509d4afcd
diff --git a/external/boost/UnpackedTarball_boost.mk b/external/boost/UnpackedTarball_boost.mk
index a97964b..35f77ad 100644
--- a/external/boost/UnpackedTarball_boost.mk
+++ b/external/boost/UnpackedTarball_boost.mk
@@ -84,6 +84,8 @@ boost_patches += boost_1_60_0.undef.warning.patch
boost_patches += boost.wdeprecated-auto_ptr.patch.0
boost_patches += boost_1_60_0.android.undef.warning.patch
+boost_patches += fallthrough.patch.0
+
$(eval $(call gb_UnpackedTarball_UnpackedTarball,boost))
$(eval $(call gb_UnpackedTarball_set_tarball,boost,$(BOOST_TARBALL)))
diff --git a/external/boost/fallthrough.patch.0 b/external/boost/fallthrough.patch.0
new file mode 100644
index 0000000..f8985bd
--- /dev/null
+++ b/external/boost/fallthrough.patch.0
@@ -0,0 +1,26 @@
+--- boost/format/parsing.hpp
++++ boost/format/parsing.hpp
+@@ -267,6 +267,7 @@
+ switch ( wrap_narrow(fac, *start, 0) ) {
+ case 'X':
+ fpar->fmtstate_.flags_ |= std::ios_base::uppercase;
++ BOOST_FALLTHROUGH;
+ case 'p': // pointer => set hex.
+ case 'x':
+ fpar->fmtstate_.flags_ &= ~std::ios_base::basefield;
+@@ -280,6 +281,7 @@
+
+ case 'E':
+ fpar->fmtstate_.flags_ |= std::ios_base::uppercase;
++ BOOST_FALLTHROUGH;
+ case 'e':
+ fpar->fmtstate_.flags_ &= ~std::ios_base::floatfield;
+ fpar->fmtstate_.flags_ |= std::ios_base::scientific;
+@@ -291,6 +293,7 @@
+ case 'f':
+ fpar->fmtstate_.flags_ &= ~std::ios_base::floatfield;
+ fpar->fmtstate_.flags_ |= std::ios_base::fixed;
++ BOOST_FALLTHROUGH;
+ case 'u':
+ case 'd':
+ case 'i':
diff --git a/mysqlc/source/mysqlc_preparedstatement.cxx b/mysqlc/source/mysqlc_preparedstatement.cxx
index a0d3f8f..8122424 100644
--- a/mysqlc/source/mysqlc_preparedstatement.cxx
+++ b/mysqlc/source/mysqlc_preparedstatement.cxx
@@ -564,8 +564,8 @@ void SAL_CALL OPreparedStatement::setObjectWithInfo(sal_Int32 _parameterIndex, c
setDouble( _parameterIndex, nValue );
break;
}
+ BOOST_FALLTHROUGH;
}
- // run through
case DataType::CHAR:
case DataType::VARCHAR:
@@ -591,8 +591,8 @@ void SAL_CALL OPreparedStatement::setObjectWithInfo(sal_Int32 _parameterIndex, c
setFloat(_parameterIndex,nValue);
break;
}
+ BOOST_FALLTHROUGH;
}
- // run through if we couldn't set a float value
case DataType::DOUBLE:
{
More information about the Libreoffice-commits
mailing list