diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2018-10-09 10:28:48 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2018-10-09 14:47:17 +0200 |
commit | 7ceee0f1ec0e349d0df4980d7fdedbd13c7917c5 (patch) | |
tree | 616ab419fe0f01e94740de7faacb393775420589 /shell | |
parent | 664db0d945fbb23e115eeea8377e3a4e88541da1 (diff) |
Extend loplugin:redundantinline to catch inline functions w/o external linkage
...where "inline" (in its meaning of "this function can be defined in multiple
translation units") thus doesn't make much sense. (As discussed in
compilerplugins/clang/redundantinline.cxx, exempt such "static inline" functions
in include files for now.)
All the rewriting has been done automatically by the plugin, except for one
instance in sw/source/ui/frmdlg/column.cxx that used to involve an #if), plus
some subsequent solenv/clang-format/reformat-formatted-files.
Change-Id: Ib8b996b651aeafc03bbdc8890faa05ed50517224
Reviewed-on: https://gerrit.libreoffice.org/61573
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'shell')
-rw-r--r-- | shell/source/all/xml_parser.cxx | 2 | ||||
-rw-r--r-- | shell/source/sessioninstall/SyncDbusSessionHelper.cxx | 2 | ||||
-rw-r--r-- | shell/source/tools/lngconvex/lngconvex.cxx | 4 | ||||
-rw-r--r-- | shell/source/unix/sysshell/recently_used_file.cxx | 2 |
4 files changed, 5 insertions, 5 deletions
diff --git a/shell/source/all/xml_parser.cxx b/shell/source/all/xml_parser.cxx index 522203b040ae..fd24e3c16919 100644 --- a/shell/source/all/xml_parser.cxx +++ b/shell/source/all/xml_parser.cxx @@ -54,7 +54,7 @@ namespace /* private */ return p; } - inline xml_parser* get_parser_instance(void* data) + xml_parser* get_parser_instance(void* data) { return static_cast<xml_parser*>(XML_GetUserData( static_cast<XML_Parser>(data))); diff --git a/shell/source/sessioninstall/SyncDbusSessionHelper.cxx b/shell/source/sessioninstall/SyncDbusSessionHelper.cxx index 09673698de9e..cfe971af958b 100644 --- a/shell/source/sessioninstall/SyncDbusSessionHelper.cxx +++ b/shell/source/sessioninstall/SyncDbusSessionHelper.cxx @@ -36,7 +36,7 @@ namespace } GError*& getRef() { return m_pError; } }; - inline GDBusProxy* lcl_GetPackageKitProxy(const OUString& sInterface) + GDBusProxy* lcl_GetPackageKitProxy(const OUString& sInterface) { const OString sFullInterface = OUStringToOString("org.freedesktop.PackageKit." + sInterface, RTL_TEXTENCODING_ASCII_US); GDBusProxy* proxy = nullptr; diff --git a/shell/source/tools/lngconvex/lngconvex.cxx b/shell/source/tools/lngconvex/lngconvex.cxx index d8a1d8837d96..ff8126285ff6 100644 --- a/shell/source/tools/lngconvex/lngconvex.cxx +++ b/shell/source/tools/lngconvex/lngconvex.cxx @@ -72,10 +72,10 @@ void ShowUsage() std::cout << "-rcf Name of the resource file footer" << std::endl; } -inline OUString OStringToOUString(const OString& str) +OUString OStringToOUString(const OString& str) { return OStringToOUString(str, osl_getThreadTextEncoding()); } -inline OString OUStringToOString(const OUString& str) +OString OUStringToOString(const OUString& str) { return OUStringToOString(str, osl_getThreadTextEncoding()); } /** Get the directory where the module diff --git a/shell/source/unix/sysshell/recently_used_file.cxx b/shell/source/unix/sysshell/recently_used_file.cxx index 458a6da2fe79..746704dbfbd0 100644 --- a/shell/source/unix/sysshell/recently_used_file.cxx +++ b/shell/source/unix/sysshell/recently_used_file.cxx @@ -35,7 +35,7 @@ const char SLASH[] = "/"; namespace { -inline void ensure_final_slash(/*inout*/ OUString& path) +void ensure_final_slash(/*inout*/ OUString& path) { if (!path.isEmpty() && (SLASH[0] != path.pData->buffer[path.getLength() - 1])) |