[Libreoffice-commits] core.git: i18nutil/source include/i18nutil include/IwyuFilter_include.yaml

Libreoffice Gerrit user logerrit at kemper.freedesktop.org
Wed Nov 7 09:06:25 UTC 2018


 i18nutil/source/utility/casefolding.cxx     |    3 +++
 i18nutil/source/utility/oneToOneMapping.cxx |    1 +
 i18nutil/source/utility/paper.cxx           |    1 +
 i18nutil/source/utility/widthfolding.cxx    |    1 +
 include/IwyuFilter_include.yaml             |    6 ++++++
 include/i18nutil/casefolding.hxx            |    4 ++--
 include/i18nutil/oneToOneMapping.hxx        |    3 ---
 include/i18nutil/paper.hxx                  |    3 ++-
 include/i18nutil/searchopt.hxx              |    1 -
 include/i18nutil/transliteration.hxx        |    1 -
 include/i18nutil/widthfolding.hxx           |    6 ++++--
 11 files changed, 20 insertions(+), 10 deletions(-)

New commits:
commit 511061b0d392f238a18a27477148731e3437b5ae
Author:     Gabor Kelemen <kelemeng at ubuntu.com>
AuthorDate: Mon Oct 22 10:19:10 2018 +0200
Commit:     Miklos Vajna <vmiklos at collabora.co.uk>
CommitDate: Wed Nov 7 10:04:47 2018 +0100

    tdf#42949 Fix IWYU warnings in include/i18nutil/*
    
    Found with bin/find-unneeded-includes
    Only removal proposals are dealt with here.
    
    Change-Id: Icc3cb8118b225c9b19b451b2a6463c844ef4162d
    Reviewed-on: https://gerrit.libreoffice.org/62459
    Tested-by: Jenkins
    Reviewed-by: Miklos Vajna <vmiklos at collabora.co.uk>

diff --git a/i18nutil/source/utility/casefolding.cxx b/i18nutil/source/utility/casefolding.cxx
index 140fa8cd71e0..0b01565a4466 100644
--- a/i18nutil/source/utility/casefolding.cxx
+++ b/i18nutil/source/utility/casefolding.cxx
@@ -19,8 +19,11 @@
 
 #include <i18nutil/casefolding.hxx>
 #include "casefolding_data.h"
+#include <i18nutil/oneToOneMapping.hxx>
 #include <i18nutil/widthfolding.hxx>
 #include <i18nutil/transliteration.hxx>
+#include <com/sun/star/lang/Locale.hpp>
+#include <com/sun/star/uno/RuntimeException.hpp>
 
 using namespace com::sun::star::lang;
 using namespace com::sun::star::uno;
diff --git a/i18nutil/source/utility/oneToOneMapping.cxx b/i18nutil/source/utility/oneToOneMapping.cxx
index 0fdea0599004..d321b49de765 100644
--- a/i18nutil/source/utility/oneToOneMapping.cxx
+++ b/i18nutil/source/utility/oneToOneMapping.cxx
@@ -18,6 +18,7 @@
  */
 
 #include <i18nutil/oneToOneMapping.hxx>
+#include <string.h>
 
 namespace i18nutil {
 
diff --git a/i18nutil/source/utility/paper.cxx b/i18nutil/source/utility/paper.cxx
index c2728f697183..9c1476c0dc03 100644
--- a/i18nutil/source/utility/paper.cxx
+++ b/i18nutil/source/utility/paper.cxx
@@ -30,6 +30,7 @@
 #include <utility>
 #include <cstdlib>
 #include <unotools/configmgr.hxx>
+#include <com/sun/star/lang/Locale.hpp>
 
 #ifdef UNX
 #include <stdio.h>
diff --git a/i18nutil/source/utility/widthfolding.cxx b/i18nutil/source/utility/widthfolding.cxx
index 535f76a894c4..62c4aa14b1e5 100644
--- a/i18nutil/source/utility/widthfolding.cxx
+++ b/i18nutil/source/utility/widthfolding.cxx
@@ -18,6 +18,7 @@
  */
 
 #include <i18nutil/widthfolding.hxx>
+#include <com/sun/star/uno/Sequence.hxx>
 #include "widthfolding_data.h"
 
 using namespace com::sun::star::uno;
diff --git a/include/IwyuFilter_include.yaml b/include/IwyuFilter_include.yaml
index cdcaee4bfe10..3a29d0881a9c 100644
--- a/include/IwyuFilter_include.yaml
+++ b/include/IwyuFilter_include.yaml
@@ -278,3 +278,9 @@ blacklist:
     - com/sun/star/lang/XInitialization.hpp
     - com/sun/star/lang/XServiceInfo.hpp
     - com/sun/star/xml/sax/XFastParser.hpp
+    include/i18nutil/casefolding.hxx:
+    # Needed for template
+    - o3tl/typed_flags_set.hxx
+    include/i18nutil/transliteration.hxx:
+    # Needed for template
+    - o3tl/typed_flags_set.hxx
diff --git a/include/i18nutil/casefolding.hxx b/include/i18nutil/casefolding.hxx
index ca29cabb4959..1b7df9e74b5e 100644
--- a/include/i18nutil/casefolding.hxx
+++ b/include/i18nutil/casefolding.hxx
@@ -20,11 +20,11 @@
 #define INCLUDED_I18NUTIL_CASEFOLDING_HXX
 
 #include <sal/types.h>
-#include <com/sun/star/lang/Locale.hpp>
-#include <com/sun/star/uno/RuntimeException.hpp>
 #include <i18nutil/i18nutildllapi.h>
 #include <o3tl/typed_flags_set.hxx>
 
+namespace com { namespace sun { namespace star { namespace lang { struct Locale; } } } }
+
 enum class TransliterationFlags;
 
 enum class MappingType {
diff --git a/include/i18nutil/oneToOneMapping.hxx b/include/i18nutil/oneToOneMapping.hxx
index 80550d957158..b479005efe93 100644
--- a/include/i18nutil/oneToOneMapping.hxx
+++ b/include/i18nutil/oneToOneMapping.hxx
@@ -19,14 +19,11 @@
 #ifndef INCLUDED_I18NUTIL_ONETOONEMAPPING_HXX
 #define INCLUDED_I18NUTIL_ONETOONEMAPPING_HXX
 
-#include <rtl/ustring.hxx>
 #include <i18nutil/i18nutildllapi.h>
 #include <memory>
 
 namespace i18nutil {
 
-class widthfolding;
-
 struct OneToOneMappingTable_t
 {
     sal_Unicode first;
diff --git a/include/i18nutil/paper.hxx b/include/i18nutil/paper.hxx
index 75f77de05401..2b28942bc1e4 100644
--- a/include/i18nutil/paper.hxx
+++ b/include/i18nutil/paper.hxx
@@ -22,7 +22,8 @@
 
 #include <i18nutil/i18nutildllapi.h>
 #include <rtl/string.hxx>
-#include <com/sun/star/lang/Locale.hpp>
+
+namespace com { namespace sun { namespace star { namespace lang { struct Locale; } } } }
 
 //!! The values of the following enumerators must correspond to the array position
 //!! of the respective paper size in the file i18nutil/source/utility/paper.cxx
diff --git a/include/i18nutil/searchopt.hxx b/include/i18nutil/searchopt.hxx
index 0acf47dfd82b..56bfaa3f87a6 100644
--- a/include/i18nutil/searchopt.hxx
+++ b/include/i18nutil/searchopt.hxx
@@ -23,7 +23,6 @@
 #include <com/sun/star/lang/Locale.hpp>
 #include <com/sun/star/util/SearchAlgorithms.hpp>
 #include <com/sun/star/util/SearchOptions2.hpp>
-#include <i18nutil/i18nutildllapi.h>
 #include <i18nutil/transliteration.hxx>
 
 namespace i18nutil
diff --git a/include/i18nutil/transliteration.hxx b/include/i18nutil/transliteration.hxx
index f962929b2bdc..62c8af82e61f 100644
--- a/include/i18nutil/transliteration.hxx
+++ b/include/i18nutil/transliteration.hxx
@@ -19,7 +19,6 @@
 #ifndef INCLUDED_I18NUTIL_TRANSLITERATION_HXX
 #define INCLUDED_I18NUTIL_TRANSLITERATION_HXX
 
-#include <sal/types.h>
 #include <com/sun/star/i18n/TransliterationModules.hpp>
 #include <com/sun/star/i18n/TransliterationModulesExtra.hpp>
 #include <o3tl/typed_flags_set.hxx>
diff --git a/include/i18nutil/widthfolding.hxx b/include/i18nutil/widthfolding.hxx
index ba0eb8f184dc..310bf954a304 100644
--- a/include/i18nutil/widthfolding.hxx
+++ b/include/i18nutil/widthfolding.hxx
@@ -20,10 +20,12 @@
 #define INCLUDED_I18NUTIL_WIDTHFOLDING_HXX
 
 #include <sal/types.h>
-#include <com/sun/star/uno/Sequence.hxx>
-#include <i18nutil/oneToOneMapping.hxx>
+#include <rtl/ustring.hxx>
 #include <i18nutil/i18nutildllapi.h>
 
+namespace com { namespace sun { namespace star { namespace uno { template <typename > class Sequence; } } } }
+namespace i18nutil { class oneToOneMapping; }
+
 namespace i18nutil {
 
 #define WIDTHFOLDNIG_DONT_USE_COMBINED_VU 0x01


More information about the Libreoffice-commits mailing list