1457 Commits

Author SHA1 Message Date
Stephan Bergmann
2446d2b2fb Avoid expensive calls to containsPreprocessingConditionalInclusion
Change-Id: I42981a23f75298591b2c3b073aea66426220f3e2
2017-11-07 12:47:37 +01:00
Noel Grandin
9610bab093 loplugin:constparams in sd
Change-Id: Id4b68ca0509111396ed354f4cda43d663083cad0
Reviewed-on: https://gerrit.libreoffice.org/44388
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-11-07 12:07:39 +01:00
Stephan Bergmann
b35bb38f18 Clean away temporarily added using declarations
Change-Id: I26734c13515394162d88351a1cbe2b20abdac865
2017-11-07 11:50:47 +01:00
Stephan Bergmann
07b8711526 Memoize ignoreLocation results
...which, according to callgrind, reduces instruction fetch count spent on
compiling sw/source/core/layout/paintfrm.cxx (randomly selected because it is
rather large) by 5% from 41,992,064,226 to 39,861,989,855 (function main() in
clang-6.0).

This is best done by forwarding ignoreLocation calls from Plugin to the
PluginHandler signleton, but due to the tight mutual coupling between plugin.hxx
and pluginhandler.hxx that unfortunately required some reorganization (and two
outstanding TODO clean-ups of temporarily introduced using declarations in
plugin.hxx).

Change-Id: Ia4270517d194def7db7ed80cb6894e9c473e9499
2017-11-07 11:19:30 +01:00
Noel Grandin
455e4011f7 improve constparam loplugin
lots of little fixes to make the logic less pessimistic

Change-Id: If368822984250b11b98c56f5890177a1402e8660
Reviewed-on: https://gerrit.libreoffice.org/44168
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-11-02 10:45:01 +01:00
Stephan Bergmann
ecbaf98062 -I$(dir $(3)) in gb_CObject__command_pattern is no longer needed
...at least in com_GCC_class.mk (com_MSC_class.mk will be addressed in a follow-
up commit), after the recent loplugin:includeform clean-up.

Two static libraries built from external sources needed adjustment, two
compilerplugin tests needed adjustment (which wasn't found by
loplugin:includeform, by design), and one more adjustment in
sal/textenc/generate/.

Change-Id: Idad5ae355a02ae130369a9a45b5f5925ab48ffef
Reviewed-on: https://gerrit.libreoffice.org/44174
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2017-11-01 23:17:41 +01:00
Noel Grandin
21cd473a97 new loplugin: constmethod
parked in store/ for now, because, as I worked my way up the layers of
modules, the higher I got, the more false+ I got when trying to only
make changes that preserved logical-constness.

Change-Id: I4acd2c4416775f7c6a3d91eb0bce048630ccaff5
2017-10-30 16:30:59 +02:00
Stephan Bergmann
2db621da66 Adapt loplugin:includeform to Windows \ path separator
This can also call loplugin::isSamePathname with two paths that both contain
backslashes, so finally make it (and hasPathnamePrefix) symmetric in which
arguments my contain backslashes.

Change-Id: I0465988d9d41e21c5660cbdbd1558543860ae1ad
2017-10-27 15:57:48 +02:00
Noel Grandin
e7dadcf739 revert small part of previous commit
not necessary after all

Change-Id: I050ed0cc140969f2d32839f3a7841b240fd0efd0
2017-10-27 14:09:49 +02:00
Noel Grandin
569c7da252 extract some common code for checking if a functions address was taken
Change-Id: I292b4e9bf17c83f83ff43ac4c5870d33092d0c71
2017-10-27 13:55:43 +02:00
Stephan Bergmann
5670f65cce -Werror=unused-function
Change-Id: I2858c6cb74b96ffe6a799dc2ab02cbbe1c56abc7
2017-10-27 13:45:39 +02:00
Noel Grandin
8136a87d9a loplugin:constantparam was not always using canonical location for function
Change-Id: I8a15da534ba2cf9968cba0ee1f1bb74d7e3a0d54
2017-10-27 10:31:42 +02:00
Noel Grandin
8a39134d5c no need to build the parent tree twice
lets just use the built in parents stuff

Change-Id: I7bb705acfcd6c8c18168676b0cdb13c26ba5b95a
2017-10-27 10:31:42 +02:00
Noel Grandin
5585bc2fbb rename loplugin::Plugin::parentStmt
to getParentStmt and rename parentFunctionDecl to getParentFunctionDecl,
so I don't keep using accidentally naming my variables the same as the
functions.

Change-Id: I66f9452458c8b439e5132191ac5219fb6d420708
2017-10-27 10:31:42 +02:00
Stephan Bergmann
1061875d67 Make loplugin:implicitboolconversion find the same in C++17 and pre-C++17
...see a2d814ac1d7beb6fbe4b9cb7b75814f4b08b8e59
"loplugin:implicitboolconversion" and 24eeb4d286471e4a2103c15efc624a565112ca32
"loplugin:implicitboolconversion" for things previously only found in C++17.  As
expected, no further occurrences were found.

Change-Id: Id0ab621b82dc3c40c8b5801413fceb73ade1408a
2017-10-26 21:07:17 +02:00
Stephan Bergmann
e02e0f4081 Use compat::getSubExprAsWritten; clean up
Change-Id: I8f984c3b3833437f6b4d65ab99da608a6868ff74
2017-10-26 21:04:03 +02:00
Stephan Bergmann
084f454e8c More loplugin:unnecessaryparen
81892b2037453108b9bde1512a500cf3b2ce438a "loplugin:unnecessaryparen when
compiling as C++17, so the ParenExpr is no longer hidden behind
ExprWithCleanups/CXXConstructExpr/MaterializedTemporaryExpr wrappers" gave me
the idea to generally look though IgnoreImplicit instead of IngoreImpCasts in
loplugin:unnecessaryparen.  However, that would still not look through implicit
CXXConstructExpr, so would still not have found the occurrences in
81892b2037453108b9bde1512a500cf3b2ce438a when compiling in pre-C++17 mode.
Therefore, let ignoreAllImplicit also look through CXXConstructExpr.  (I am not
entirely sure in which situations non-implicit CXXConstructExpr---that should
thus not be ignored---would occur, but assume they would be underneath something
like a CXXFunctionalCastExpr, which is not ignored.)

Change-Id: I947d08742e1809150ecc34a7abe84cca5e0ce843
2017-10-26 10:27:48 +02:00
Noel Grandin
80a30219c4 new loplugin:dodgyswitch
and fix bug in ScriptDocument::getTitle
which has been there since

    commit e304ba66f4aba5cc55612508b5738a1ed26a7904
    Date:   Thu Mar 15 14:59:30 2007 +0000
    INTEGRATION: CWS basmgr02 (1.1.2); FILE ADDED

plugin is off by default since it uses expensive parentStmt() calls

Change-Id: Id0f16baec48e0381e0083594d7e59b58b023da2f
Reviewed-on: https://gerrit.libreoffice.org/43750
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-10-25 08:32:16 +02:00
Stephan Bergmann
acb3ed0615 loplugin:includeform
Consistently use the #include "..." form for exactly those cases where the
included file is located next to the including file, see the mail thread
starting at
<https://lists.freedesktop.org/archives/libreoffice/2017-October/078601.html>
"C[++]: Normalizing include syntax ("" vs <>)".  (For UNO API include files,
see 189abcf0db61c41a565bd355294bf6e712fc3e5a "loplugin:includeform: UNO API
include files".)

(Some of the commits done earlier with messages containing "Change done in
preparation of loplugin:includeform" etc. were based on a somewhat different
earlier version of this plugin and would not be necessary with the current form.
But they are harmless and reverting them would probably cause more noise than
benefit, so just leave them in.)

Change-Id: I9fe9268ed84d31b5df71857a2e535972b11254ce
Reviewed-on: https://gerrit.libreoffice.org/43730
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2017-10-24 11:49:25 +02:00
Stephan Bergmann
5807952ef7 loplugin:redundantcast: Do warn about convoluted dynamic_cast to self
...that the compiler is free to elide anyway.  (See
4e7ffc0a69dac31ca7e0f1649f1697a1ff8d6e5f "Avoid compiler eliding#redundant
dynamic_cast" and 380d6afe5fd691f6ad4b17fc38b79b9fca4ba906 "Remove redundant
asserts involving dynamic_cast".)

Change-Id: I3f75154fee3e978b7ba95a5a27589417065599bd
2017-10-22 11:57:44 +02:00
Stephan Bergmann
66b1854252 Make sure TypeCheck has a non-deleted default ctor
...as needed by

> core/compilerplugins/clang/check.cxx:19:19: error: call to implicitly-deleted default constructor of 'loplugin::TypeCheck'
>         ? *this : TypeCheck();
>                   ^
> core/compilerplugins/clang/check.hxx:76:5: note: explicitly defaulted function was implicitly deleted here
>     TypeCheck() = default;
>     ^
> core/compilerplugins/clang/check.hxx:78:27: note: default constructor of 'TypeCheck' is implicitly deleted because field 'type_' of const-qualified type 'const clang::QualType' would not be initialized
>     clang::QualType const type_;
>                           ^

after https://llvm.org/svn/llvm-project/cfe/trunk@315194 "Make SourceLocation,
QualType and friends have constexpr constructors" defaulted the clang::QualType
ctor.

Change-Id: Idaeaa4499cea877fd5d66c18b8fce24b7808ba04
2017-10-22 11:51:36 +02:00
Noel Grandin
ead920a48a loplugin:redundantcast handle dynamic_cast
Change-Id: I7855c76e820efce96778b1c19ec71dffcc4b4abb
Reviewed-on: https://gerrit.libreoffice.org/43621
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2017-10-21 15:44:11 +02:00
Stephan Bergmann
1c680d763e Avoid loplugin:faileddyncast for "unnecessary", up-casting dynamic_cast
Change-Id: Iecb943db0aff7ffc21cc2f6adb625be369255b32
Reviewed-on: https://gerrit.libreoffice.org/43606
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-10-21 07:03:04 +02:00
Stephan Bergmann
15dce20e8b Fully ignore inappropriately named loplugins in unit-test mode
...even if they implement PPCallbacks, so filtering them out in
HandleTranslationUnit was ineffective.

Change-Id: I9df8103a50739f3176e6d63accfd0334da7faa9a
Reviewed-on: https://gerrit.libreoffice.org/43575
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Tested-by: Stephan Bergmann <sbergman@redhat.com>
2017-10-20 08:31:30 +02:00
Noel Grandin
abaf2e3b85 rename some fields
in preparation for const-method detection

Change-Id: Iecf7102892d664ded799615ce1a848a538dcfcef
2017-10-18 16:26:14 +02:00
Noel Grandin
d9575e72de loplugin:manualrefcount
this is the code I used to find naked acquire/release stuff

No need to run it all the time, so leave it in store

Change-Id: I9ac4a6f5db7cd4cbb1b63698340425eed7cb8713
2017-10-18 16:23:20 +02:00
Stephan Bergmann
4e9ebc6de4 Move lotuswordpro include files to common include directory
...that are included from both lotuswordpro/source/filter and
lotuswordpro/source/filter/xfilter.  Change done in preparation of
loplugin:includeform.

Change-Id: I7b65d3232e164af662b7de5bb49d59597803d41c
Reviewed-on: https://gerrit.libreoffice.org/43453
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2017-10-17 14:29:11 +02:00
Noel Grandin
493a7e9932 loplugin:finalclasses trim the output a little
Change-Id: Iad0f0ded624e95448421c19a04535c2511b66a02
2017-10-17 09:10:48 +02:00
Stephan Bergmann
2d3535a78a Move svx include files to common include directory
...that are included from various source directories.  Change done in
preparation of loplugin:includeform.

Change-Id: I9191e80aa721c376f17219e4d10eb83929e38e14
2017-10-16 17:31:23 +02:00
Stephan Bergmann
948c9c0a31 Use unique class names for better FlameGraph results
...of measuring loplugin performance, when gathering data with perf and all
plugins that used "Visitor" as class name were lumped together.  (Cf.
<https://whatofhow.wordpress.com/2016/06/28/plugin-flamed/>.)

Change-Id: Ie482f443faced7469528da4772e735bc2eda596d
Reviewed-on: https://gerrit.libreoffice.org/43324
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Tested-by: Stephan Bergmann <sbergman@redhat.com>
2017-10-11 14:26:44 +02:00
Stephan Bergmann
51c81a57e3 Move loplugin:bodynotinblock to store/, to improve performance
...as it was the last remaining enabled-by-default plugin that calls expensive
parentStmt.  It isn't immediately clear to me how to rewrite the plugin to not
call that, but a superset of this plugin's warnings are now also emitted by
GCC 6 -Wmisleading-indentation.

Change-Id: Ifa55cb14f6763594fe48926585df29d4d30355df
2017-10-09 09:32:46 +02:00
Noel Grandin
05400958b0 disable constparams loplugin
increases compile time too much, I will run this by hand periodically

Change-Id: I118567ef294847ff609d4de771d998ce3b57161b
2017-10-06 12:52:05 +02:00
Noel Grandin
38ccea5588 Improve performance of loplugin:flatten
...by avoiding calls to parentStmt.

Change-Id: I4f3d66a0529e9c3abf5c963bcf70db7a2afa1bf9
2017-10-06 12:44:57 +02:00
Stephan Bergmann
4fc52078f6 Improve performance of loplugin:commaoperator
...by avoiding calls to parentStmt, thereby also improving the precision of
exactly which comma operators to ignore (which turned up a handful more finds).
Also added tests.

Change-Id: Ie74f824fd7f54131aab09b59086452fb4f3ff827
Reviewed-on: https://gerrit.libreoffice.org/43181
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2017-10-06 10:05:00 +02:00
Noel Grandin
e1261e6ea6 loplugin:finalclasses in vcl
Change-Id: I7de9cd6c5569217aa8d379c6d112cd1874bca8e2
Reviewed-on: https://gerrit.libreoffice.org/43151
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-10-05 09:48:43 +02:00
Stephan Bergmann
3d1b53a099 Also suppress loplugin:flatten in C++ class member functions...
...invovling preprocessing conditionals, to actually make the unhelpful warning
on Windows about OleEmbeddedObject::changeState go away.  And while at it, make
the check for preprocessing conditionals more targeted (similar to
1084e8be44661aaeacb8801707701013eb3fcdbc "More targeted check for preprocessing
conditionals in loplugin:blockblock").

Change-Id: I0300e0a547e969520a90cd126ea8f788cc17560f
Reviewed-on: https://gerrit.libreoffice.org/42975
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2017-10-05 09:38:31 +02:00
Noel Grandin
83c00b3359 loplugin:mergerclass merge FillAttrLB with SvxFillAttrBox
Change-Id: I5dfa7689eb219548bde7ce181a0a453c84b0f066
Reviewed-on: https://gerrit.libreoffice.org/43136
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-10-05 09:05:32 +02:00
Noel Grandin
20356442cd loplugin:mergeclasses merge IInterface with SwDoc
Change-Id: I6d400540c878db4504f6830aa9a3a6a381162520
Reviewed-on: https://gerrit.libreoffice.org/43127
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-10-04 15:06:04 +02:00
Stephan Bergmann
7f0bf6220b Revert "check for unnecessary DLLPUBLIC annotations"
This reverts commit a599eeab786ecbe1b5b6509e3c792e5c1ba31248, plus follow-up
fa4431449d0306e8179f53a2a69c549800bd24bd "Avoid bogus loplugin:dllmacro
'unnecessary *DLLPUBLIC declaration ...'".  See (abandoned)
<https://gerrit.libreoffice.org/#/c/42983/> "loplugin:dllmacro: Handle implicit
member functions" how this would have needed to be extended to give consistent
results across Linux and macOS, but then would have started to remove DLLPUBLIC
from entities that apparently need to at least have default type visibility on
macOS and started to make tests fail.
2017-10-04 13:45:39 +02:00
Stephan Bergmann
1084e8be44 More targeted check for preprocessing conditionals in loplugin:blockblock
Change-Id: Ib9b6b266ed4bf4d2672aed723c7f92f58c9007b3
2017-10-04 12:03:23 +02:00
Stephan Bergmann
f4514f356a Fix test, and add missing TraverseFunctionDecl base case
Change-Id: I31f238fe931e8d890cd70b1a1eb52f042f487a76
2017-10-04 11:58:30 +02:00
Stephan Bergmann
56c9446f74 Suppress loplugin:blockblock in functions involving preprocessing conditionals
...as needed to avoid an unhelpful warning about Player::createPlayerWindow in
avmedia/source/gstreamer/gstplayer.cxx when included from
avmedia/source/gstreamer/gst_0_10.cxx (so that ENABLE_GTKSINK is not defined).

Change-Id: I6de9cc59cf8e611c4c9d939dd837499b1d2c8787
2017-10-04 11:14:43 +02:00
Noel Grandin
6ce77cac03 move stuff in i18npool/i18nutil in own namespace
instead of trying to share the css::i18n namespace, which is just very
confusing and should be left to actual UNO artifacts

Change-Id: I2f5c36bf1af9a2a98c4f997dd450d015e75ed3f6
Reviewed-on: https://gerrit.libreoffice.org/43079
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-10-04 08:39:11 +02:00
Noel Grandin
ccb1894c02 new loplugin:finalclasses
look for classes which are effectively final, but contain protected
members. These members can be made private.

Change-Id: If53d535b068b668d1aff548ebfd0fe6c51a48a0e
2017-10-03 11:15:47 +02:00
Noel Grandin
d3971ec256 new loplugin:blockblock
Change-Id: I7b68b70fa4c7234e8882f7627026959a596968fd
Reviewed-on: https://gerrit.libreoffice.org/43025
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-10-03 08:41:11 +02:00
Stephan Bergmann
2e8a95d1f8 loplugin:constparams: Ignore functions whose address is taken
(unless as the callee of a function call).  In response to
<https://gerrit.libreoffice.org/#/c/42912/> "DO NOT MERGE - error in clang
static plugin".  Many of the whitelisted functions can now be taken off the
list.

Change-Id: I04c2ee445e7973a288f42fd663d8b2d78cd3c5aa
Reviewed-on: https://gerrit.libreoffice.org/42958
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Tested-by: Stephan Bergmann <sbergman@redhat.com>
2017-09-30 15:02:22 +02:00
Stephan Bergmann
62274b24f9 Suppress loplugin:flatten in functions involving preprocessing conditionals
...as needed by clang-cl on Windows to avoid unhelpful warnings about
OleEmbeddedObject::changeState (embeddedobj/source/msole/oleembed.cxx)
containging an "if" in an "#ifdef _WIN32" block followed by "else throw".

Change-Id: I95bed29b9003db08499156ae7f885aeeea5a0158
Reviewed-on: https://gerrit.libreoffice.org/42963
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2017-09-30 13:28:43 +02:00
Stephan Bergmann
39e7a72b3e Support loplugin in clang-cl
This works at least with a recent Clang trunk (towards Clang 6.0).

In order for the plugin.dll to find the LLVM/Clang symbols, it needs to be
loaded into clang.exe not clang-cl.exe, so set CC/CXX to 'clang.exe
--driver-mode=cl ...'.

Buidling the plugin requires some linker flags that must go at the very end of
the COMPILER_PLUGINS_CXX command line, after a /link switch, so introduce
another COMPILER_PLUGINS_CXX_LINKFLAGS variable for that.  Also, clang.lib is
not installed as part of LLVM's 'cmake --build ... --target install' step, so
is not available under CLANGDIR and needs to be taken from the build tree
instead, so introduce another CLANGLIBDIR variable for that.  autogen.input
settings that work for me on Windows 8.1 with Microsoft Visual Studio 14.0 are:

> CLANGDIR=C:/llvm/inst
> CLANGLIBDIR=C:/llvm/build/lib
> COMPILER_PLUGINS_CXX=C:/PROGRA~2/MICROS~3.0/VC/bin/amd64/cl.exe /IC:\PROGRA~2\MICROS~3.0\VC\INCLUDE /IC:\PROGRA~2\MICROS~3.0\VC\ATLMFC\INCLUDE /IC:\PROGRA~2\WI3CF2~1\10\include\100102~1.0\ucrt /IC:\PROGRA~2\WI3CF2~1\NETFXSDK\46D346~1.1\include\um /IC:\PROGRA~2\WI3CF2~1\8.1\include\shared /IC:\PROGRA~2\WI3CF2~1\8.1\include\um /IC:\PROGRA~2\WI3CF2~1\8.1\include\winrt
> COMPILER_PLUGINS_CXX_LINKFLAGS=/LIBPATH:C:/PROGRA~2/MICROS~3.0/VC/LIB/amd64 /LIBPATH:C:/PROGRA~2/MICROS~3.0/VC/ATLMFC/LIB/amd64 /LIBPATH:C:/PROGRA~2/WI3CF2~1/10/lib/100102~1.0/ucrt/x64 /LIBPATH:C:/PROGRA~2/WI3CF2~1/NETFXSDK/46D346~1.1/lib/um/x64 /LIBPATH:C:/PROGRA~2/WI3CF2~1/8.1/lib/winv6.3/um/x64

(The last two are "C:/Program Files (x86)/Microsoft Visual Studio 14.0/VC/bin/
amd64/cl.exe" and translations of %INCLUDE% and %LIB% as set in the "VS2015 x64
Native Tools Command Prompt" shell.
AC_CHECK_HEADER(clang/AST/RecursiveASTVisitor.h, ...) in configure.ac wouldn't
like CXX to start with INCLUDE=... LIB=... environment variable settings, so it
wouldn't work to instead pass %INCLUDE% and %LIB% to cl.exe that way.  See
<https://wiki.documentfoundation.org/Development/clang-cl> for general
information about building with clang-cl on Windows.)

There's still some room for improvement marked "TODO".  (And some of the unused*
plugins, which are not run by default anyway, use Unix-style functionality, so
have been disabled for now.)

Change-Id: I6c28bdeb801af39ce2bae03111f455e2338d66c9
Reviewed-on: https://gerrit.libreoffice.org/42931
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2017-09-30 11:28:43 +02:00
Stephan Bergmann
0d43f5176d Access to ProcessEventsToSignal's bSignal is racy
...so spell out its single use, locking the appropriate mutex around the access

Change-Id: I8e8f47de1979f5a80cf1ad65e5ec24d25145c463
Reviewed-on: https://gerrit.libreoffice.org/42908
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2017-09-30 09:30:03 +02:00
Stephan Bergmann
fa4431449d Avoid bogus loplugin:dllmacro "unnecessary *DLLPUBLIC declaration ..."
...about the definition of __cxxabiv1::__cxa_exception in
bridges/source/cpp_uno/gcc3_linux_x86-64/share.hxx, when a declaration of that
struct has already been seen in /usr/include/c++/7/cxxabi.h in a

  #pragma GCC visibility push(default)
  ...
  #pragma GCC visibility pop

block (so that decl->getAttr<VisibilityAttr>() would point at the first of those
two pragmas).

Change-Id: I4af56be8ce84ace57a809a09da5c44d86fc4237a
2017-09-29 16:33:45 +02:00