Age | Commit message (Collapse) | Author | Files | Lines |
|
See the discussion at <https://gerrit.libreoffice.org/#/c/58170/>, and
this came up on IRC today again.
The above change broke the invariant that you can mix product and debug
(but not dbgutil) builds. Restore this, without mandating dbgutil for
the solar mutex assert code, which is useful for plain debug builds as
well.
Change-Id: I1f8bdb114b129fc4f39f186ba917e35e346a16b5
Reviewed-on: https://gerrit.libreoffice.org/85369
Tested-by: Jenkins
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
|
|
...following up on 314f15bff08b76bf96acf99141776ef64d2f1355 "Extend
loplugin:external to warn about enums".
Cases where free functions were moved into an unnamed namespace along with a
class, to not break ADL, are in:
filter/source/svg/svgexport.cxx
sc/source/filter/excel/xelink.cxx
sc/source/filter/excel/xilink.cxx
svx/source/sdr/contact/viewobjectcontactofunocontrol.cxx
All other free functions mentioning moved classes appear to be harmless and not
give rise to (silent, even) ADL breakage. (One remaining TODO in
compilerplugins/clang/external.cxx is that derived classes are not covered by
computeAffectedTypes, even though they could also be affected by ADL-breakage---
but don't seem to be in any acutal case across the code base.)
For friend declarations using elaborate type specifiers, like
class C1 {};
class C2 { friend class C1; };
* If C2 (but not C1) is moved into an unnamed namespace, the friend declaration
must be changed to not use an elaborate type specifier (i.e., "friend C1;"; see
C++17 [namespace.memdef]/3: "If the name in a friend declaration is neither
qualified nor a template-id and the declaration is a function or an
elaborated-type-specifier, the lookup to determine whether the entity has been
previously declared shall not consider any scopes outside the innermost
enclosing namespace.")
* If C1 (but not C2) is moved into an unnamed namespace, the friend declaration
must be changed too, see <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71882>
"elaborated-type-specifier friend not looked up in unnamed namespace".
Apart from that, to keep changes simple and mostly mechanical (which should help
avoid regressions), out-of-line definitions of class members have been left in
the enclosing (named) namespace. But explicit specializations of class
templates had to be moved into the unnamed namespace to appease
<https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92598> "explicit specialization of
template from unnamed namespace using unqualified-id in enclosing namespace".
Also, accompanying declarations (of e.g. typedefs or static variables) that
could arguably be moved into the unnamed namespace too have been left alone.
And in some cases, mention of affected types in blacklists in other loplugins
needed to be adapted.
And sc/qa/unit/mark_test.cxx uses a hack of including other .cxx, one of which
is sc/source/core/data/segmenttree.cxx where e.g. ScFlatUInt16SegmentsImpl is
not moved into an unnamed namespace (because it is declared in
sc/inc/segmenttree.hxx), but its base ScFlatSegmentsImpl is. GCC warns about
such combinations with enabled-by-default -Wsubobject-linkage, but "The compiler
doesn’t give this warning for types defined in the main .C file, as those are
unlikely to have multiple definitions."
(<https://gcc.gnu.org/onlinedocs/gcc-9.2.0/gcc/Warning-Options.html>) The
warned-about classes also don't have multiple definitions in the given test, so
disable the warning when including the .cxx.
Change-Id: Ib694094c0d8168be68f8fe90dfd0acbb66a3f1e4
Reviewed-on: https://gerrit.libreoffice.org/83239
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
see bt:
0 0x00007ffff209866a in std::type_info::name() const (this=0x0) at /usr/include/c++/9/typeinfo:100
1 0x00007ffff20966e1 in exceptionToStringImpl(rtl::OStringBuffer&, com::sun::star::uno::Any const&)
(sMessage="DBG_UNHANDLED_EXCEPTION in bool connectivity::hsqldb::OHsqlConnection::impl_isTextTable_nothrow(const rtl::OUString&) exception: com.sun.star.sdbc.SQLException message: Unexpected token: S in statemen"..., caught=
uno::Any("com.sun.star.sdbc.SQLException": {<com::sun::star::uno::Exception> = {Message = "Unexpected token: S in statement [s]", Context = uno::Reference to (com::sun::star::uno::XInterface *) 0x555559269238}, SQLState = "37000", ErrorCode = -11, NextException = uno::Any(void)})) at /home/julien/lo/libreoffice/tools/source/debug/debug.cxx:113
2 0x00007ffff209855d in DbgUnhandledException(com::sun::star::uno::Any const&, char const*, char const*, char const*, char const*) (caught=
uno::Any("com.sun.star.sdbc.SQLException": {<com::sun::star::uno::Exception> = {Message = "Unexpected token: S in statement [s]", Context = uno::Reference to (com::sun::star::uno::XInterface *) 0x555559269238}, SQLState = "37000", ErrorCode = -11, NextException = uno::Any(void)}), currentFunction=0x7fffdb5ca340 "bool connectivity::hsqldb::OHsqlConnection::impl_isTextTable_nothrow(const rtl::OUString&)", fileAndLineNo=0x7fffdb5ca2e8 "/home/julien/lo/libreoffice/connectivity/source/drivers/hsqldb/HConnection.cxx:301: ", area=0x7fffdb5c9f49 "connectivity.hsqldb", explanatory=0x0)
at /home/julien/lo/libreoffice/tools/source/debug/debug.cxx:418
3 0x00007fffdb58a16a in connectivity::hsqldb::OHsqlConnection::impl_isTextTable_nothrow(rtl::OUString const&) (this=0x555558a43de0, _rTableName="William Kidwell's Address Book")
at /home/julien/lo/libreoffice/connectivity/source/drivers/hsqldb/HConnection.cxx:301
https://bugs.documentfoundation.org/attachment.cgi?id=155952
Change-Id: I2bc744164b1470d8f09bcb126b02e48af180e886
Reviewed-on: https://gerrit.libreoffice.org/83245
Tested-by: Jenkins
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
|
|
I started with 32 and kept doubling the size until the site
did not need re-alloc, but clamped it at 512.
Change-Id: I55fe36b31cd3d40f86e5729337a927cf920f2af6
Reviewed-on: https://gerrit.libreoffice.org/81960
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
I started with 32 and kept doubling the size until the site
did not need re-alloc, but clamped it at 512 (e.g. in emfio/).
Change-Id: Ib7caf35a1b7e42b0e4ed8aa812493449e3eefc8f
Reviewed-on: https://gerrit.libreoffice.org/81540
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Change-Id: I12517651fb3f777fd08e384992bb3e84b340ad85
Reviewed-on: https://gerrit.libreoffice.org/80382
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Change-Id: I441a5ccef6adc8be8029178e304ff3044e812e2a
Reviewed-on: https://gerrit.libreoffice.org/79986
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Change-Id: I0a3126545f9ef98640f6dd166290e9b9e91b8355
Reviewed-on: https://gerrit.libreoffice.org/74244
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
__cxa_demangle uses malloc/free for memory management, see
<http://itanium-cxx-abi.github.io/cxx-abi/abi.html#demangler>
Change-Id: I57f8465d1c70fbef4537068fd3aefc52295e1c63
Reviewed-on: https://gerrit.libreoffice.org/71942
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
need to release the pointer we get back from demangle
Change-Id: I74f1065006fe0cd5da79d0ec5caa514d216be9a1
Reviewed-on: https://gerrit.libreoffice.org/71859
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Found with bin/find-unneeded-includes
Only removal proposals are dealt with here.
Change-Id: I47974f5c24819eb60e6724f42d51bb206dc26d21
Reviewed-on: https://gerrit.libreoffice.org/71557
Tested-by: Jenkins
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
|
|
Add exceptionToString() and getCaughtExceptionAsString() methods in
tools.
Use the new methods in DbgUnhandledException()
Add special-case case code for most of the exceptions that contain extra
fields, so all of the relevant data ends up in the log
Change-Id: I376f6549b4d7bd480202f8bff17a454657c75ece
Reviewed-on: https://gerrit.libreoffice.org/67857
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
where our QA people are more likely to trigger it
Change-Id: I4ce7c8c72e7e21f2296c0f9cc9f019aaef32ed0b
Reviewed-on: https://gerrit.libreoffice.org/58170
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Change-Id: I59591d0209ddf2bcf6e57a78dc7999d773b73ae3
Reviewed-on: https://gerrit.libreoffice.org/54805
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
and rename it to DBG_UNHANDLED_EXCEPTION, to make it more like
the SAL_WARN-type macros.
Use some macro magic to deal with different numbers of arguments.
Update the sallogareas plugin to check the area parameter of
DBG_UNHANDLED_EXCEPTION.
Change-Id: Ie790223244c3484f41acb3679c043fb9b438e7c4
Reviewed-on: https://gerrit.libreoffice.org/52073
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
with command
> git grep -l osl/diagnose.h *.cxx |
xargs grep -L -w 'OSL_\w*' |
xargs sed -i '/#include *\(<\|\"\)osl\/diagnose.h\(>\|\"\).*/d'
headers need more work
Change-Id: I906519ebbd47a04703b4fa5943b2f7abea7a97ab
Reviewed-on: https://gerrit.libreoffice.org/37350
Tested-by: Jochen Nitschke <j.nitschke+logerrit@ok.de>
Reviewed-by: Michael Stahl <mstahl@redhat.com>
|
|
Change-Id: Ic80f2ed2c0fdff20d1ee1968bec2840bf914fb5e
|
|
put more useful info on the same line, and indent following lines, to
visually separate them from new log messages.
Change-Id: Ieda71aebf68420a0521ce98c621b0236d533bc53
|
|
Change-Id: I68c67e77a2759c8542dd4a44a78a9fcf8aa7dcc0
Reviewed-on: https://gerrit.libreoffice.org/26056
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Tested-by: Noel Grandin <noelgrandin@gmail.com>
|
|
Change-Id: Ia5acfb564f913d52cd25b5d64d06b5280b94cb72
|
|
Change-Id: I695ff721efd63b8ca0dd3c61ba5a4fef2c43cde6
Reviewed-on: https://gerrit.libreoffice.org/19854
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Tested-by: Noel Grandin <noelgrandin@gmail.com>
|
|
Compile in the DbgUnhandledException function always.
Change-Id: I302954598e599e8db71967974b18ade54ca2de13
|
|
See (short) discussion on the mailing list, "How was it again, is the
DbgDialog useful?".
Change-Id: Ibde1eb13f16edf94f1f7aebd0befd1b0b171d5c4
|
|
Change-Id: Iedee28da32a4333a414e06877f87851345bb4e9b
|
|
Stumbled across such redundant visibility re-specifications when looking at the
odd case of cppu_unsatisfied_iquery_msg declared CPPU_DLLPUBLIC in
cppu/source/cppu/cppu_opt.cxx and used in inline code in
include/com/sun/star/uno/Reference.hxx with only a declaration lacking
CPPU_DLLPUBLIC visible, and wondering how that actually works on Windows.
However, this plugin is probably not worth it being run all the time, so
committing it to compilerplugins/clang/store/.
Change-Id: Ibc3c4e7499213de1b419ce7eb85455cb832e1510
|
|
This reverts commit 146bd125a01742b2a6561a4a23735f37867d8221,
Clang's r224465 does not look really useful the way it is, so work around
that directly in Clang for now.
|
|
Change-Id: I3ee32c5bd379bb851f8f255faa93d96227dcff84
|
|
So that this is always wrong (on this platform) to write:
reinterpret_cast<foo>(reinterpret_cast<long>(bar))
it should be:
renterpret_cast<foo>(reinterpret_cast<sal_uIntPtr>(bar))
Change-Id: Ia286246ee1616988f755c2d2054b26efacc51af0
Reviewed-on: https://gerrit.libreoffice.org/13366
Reviewed-by: Michael Stahl <mstahl@redhat.com>
Tested-by: Michael Stahl <mstahl@redhat.com>
|
|
I introduce a template method into the PTR_CAST machinery
to maintain constness.
There is now a FIXME in sd/../docshell.cxx because I needed
to use a dynamic_cast there to work around the games it appears
to be playing with OLE in-place activation.
Signed-off-by: Stephan Bergmann <sbergman@redhat.com>,
dropping the GCC-extension, unnecessary use of typeof from tools/rtti.hxx
Change-Id: Iba5ace1aa27e02b34fcc91af1e658c43371afd03
|
|
Change-Id: Idc0f3ef53f48b2e77e4cecbcdbbc44a115c6ec2e
|
|
Change-Id: I66b3dc79998de018eae1c7eff8ce23f95e3c3f33
|
|
Change-Id: I1bc585af8f0189dfa219bd42a5f09871a006c6ea
|
|
Change-Id: Id5e3191ea1a505bd7d46af355edb99e184b5fcb1
|
|
Change-Id: I13adca8c2f929c8a9226b26ef57b26363dfdf0b3
|
|
Change-Id: Ia2d7eaaa1381fe46839b0d52a91bdc3a439fa418
|
|
...since the osl/diagnose.h macros got rebased onto sal/log.hxx, so remove the
corresponding tools/debug.h functionality.
Change-Id: Ife4b5b1a2608230d0dbfc3fa8852243c89ed292f
|
|
Change-Id: Ief6661ed4bb57546014deef5b10d20fc3a4894fe
|
|
...and thus DgbData::nWarningOut is unused, too.
Change-Id: I388d2be7dafbfdc173a731dc7daf1c8b5efcd61d
|
|
Change-Id: I5ae5318685ffe45bd9616d06eea21a93585715f2
|
|
Change-Id: I92fd33e020772eac735f133f467207da9635e9b4
|
|
--enable-dbgutils
|
|
Change-Id: I7b48d8b9e162f9e4447bfcfcc0bbd1158bd35f5b
|
|
They are practically always useless, often misleading or obsolete.
Change-Id: I2d32182a31349c9fb3b982498fd22d93e84c0c0c
|
|
...and clean up some includes.
Change-Id: Ia5843cd38f967722d7173a6c87fba26064e3ffd6
|
|
Compiler plugin to replace with matching number(), boolean() or OUString ctor,
ran it, few manual tweaks, mark as really deprecated.
Change-Id: I4a79bdbcf4c460d21e73b635d2bd3725c22876b2
|
|
Change-Id: I6a92196f33d7a5278c7dcc426112e9c56d582655
Reviewed-on: https://gerrit.libreoffice.org/4627
Reviewed-by: Norbert Thiebaud <nthiebaud@gmail.com>
Tested-by: Norbert Thiebaud <nthiebaud@gmail.com>
|
|
which I broke in commit 863d38fbfa4fb4861e476828c46410602100919e
"move DBG_UNHANDLED_EXCEPTION out of line"
Change-Id: Ic30e985cc356d81013ced1ce74ec6c78469d9882
|
|
caused by my commit
863d38fbfa4fb4861e476828c46410602100919e "move DBG_UNHANDLED_EXCEPTION out of line"
Change-Id: Idfd84d987ba9151ba476ce0516a9e5fbdb2003ec
|
|
makes it easier to set a breakpoint on it.
Plus it's getting a little big to be a macro.
Change-Id: I2827aa3618ba966fbc85a4a56e0e794a55630730
Reviewed-on: https://gerrit.libreoffice.org/3988
Reviewed-by: Fridrich Strba <fridrich@documentfoundation.org>
Tested-by: Fridrich Strba <fridrich@documentfoundation.org>
|
|
Change-Id: Ifaa1637122d6f9cae1e29b77ac36ca5d1f220aed
|