Age | Commit message (Collapse) | Author |
|
("The Java Native Interface" by Sheng Liang, Addison-Wesley 1999, states on
page 211: "This function [ExceptionDescribe] has the side effect of clearing
the pending exception." And since Java 10, the documentation of
ExceptionDescription at <https://docs.oracle.com/javase/10/docs/specs/jni/
functions.html#exceptiondescribe> states that "[t]he pending exception is
cleared as a side-effect of calling this function", even though for Java 8
<https://docs.oracle.com/javase/8/docs/technotes/guides/jni/spec/functions.html#
ExceptionDescribe> does not mention that. So assume that calling
ExceptionDescribe always makes calling ExceptionClear superfluous.)
Change-Id: I4f89eb44768d436a224d7027afb5e7a93f092f29
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/88050
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
which is much better for CPU cache, since the representation is more
compact, and since we almost always do insert() in pointer order,
there is surprisingly little sorting
Also add a count() method for compatibility with std::set and the
proposed std::flat_set
Change-Id: I2a3211dc59919cfec5cac1497530a4c3600d50ca
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87793
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Change-Id: Iab35a8b85b3ba1df791c774f40b037f9420a071a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/86708
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Change-Id: Ie23019fe0b86f16820dd68c647c4ce15bbbb42dc
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87575
Tested-by: Jenkins
Reviewed-by: Muhammet Kara <muhammet.kara@collabora.com>
|
|
"Find explicit casts from signed to unsigned integer in comparison against
unsigned integer, where the cast is presumably used to avoid warnings about
signed vs. unsigned comparisons, and could thus be replaced with
o3tl::make_unsigned for clairty." (compilerplugins/clang/unsignedcompare.cxx)
o3tl::make_unsigned requires its argument to be non-negative, and there is a
chance that some original code like
static_cast<sal_uInt32>(n) >= c
used the explicit cast to actually force a (potentially negative) value of
sal_Int32 to be interpreted as an unsigned sal_uInt32, rather than using the
cast to avoid a false "signed vs. unsigned comparison" warning in a case where
n is known to be non-negative. It appears that restricting this plugin to non-
equality comparisons (<, >, <=, >=) and excluding equality comparisons (==, !=)
is a useful heuristic to avoid such false positives. The only remainging false
positive I found was 0288c8ffecff4956a52b9147d441979941e8b87f "Rephrase cast
from sal_Int32 to sal_uInt32".
But which of course does not mean that there were no further false positivies
that I missed. So this commit may accidentally introduce some false hits of the
assert in o3tl::make_unsigned. At least, it passed a full (Linux ASan+UBSan
--enable-dbgutil) `make check && make screenshot`.
It is by design that o3tl::make_unsigned only accepts signed integer parameter
types (and is not defined as a nop for unsigned ones), to avoid unnecessary uses
which would in general be suspicious. But the STATIC_ARRAY_SELECT macro in
include/oox/helper/helper.hxx is used with both signed and unsigned types, so
needs a little oox::detail::make_unsigned helper function for now. (The
ultimate fix being to get rid of the macro in the first place.)
Change-Id: Ia4adc9f44c70ad1dfd608784cac39ee922c32175
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87556
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
Change-Id: Ice7c0ecc8ee05a5c3b0af458ceeee8191bdde322
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/86752
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
Change-Id: I42b59c9d22edb987c55aace700934fdab95f83f7
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/86719
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
Change-Id: I1c1e7b42211c51f572698efd3135e388f8fb2979
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/86648
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
Change-Id: Ia133c1a7549d81f2e88e34ab7e6c9ea578c745ae
Reviewed-on: https://gerrit.libreoffice.org/85702
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Change-Id: I8eadedbdf5f4bee218ae2f39c76300fc0624912b
Reviewed-on: https://gerrit.libreoffice.org/84374
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
Change-Id: Ib40fad986f99d02e58f0564fb68608e86989173c
Reviewed-on: https://gerrit.libreoffice.org/84325
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
1) https://cgit.freedesktop.org/libreoffice/core/commit/?id=4e1ae2a9a0d2d9185b49677fa4ea2a2b1fe8bab2
I had let "size" and "fields" initialized twice instead of initializing only
2) https://cgit.freedesktop.org/libreoffice/core/commit/?id=e6ab01ce532d1db01579b70bd476b2f643522bf9
put back original order for NestedKeyImpl and adjust initialization accordingly
Change-Id: I6ca4e6520558011c359f8ea089b6d431ad79edfe
Reviewed-on: https://gerrit.libreoffice.org/83810
Tested-by: Jenkins
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
|
|
+ fix:
/home/tdf/lode/jenkins/workspace/lo_gerrit/Config/linux_clang_dbgutil_64/connectivity/source/drivers/mork/MStatement.cxx:64:6: error: no need to explicitly init an instance of 'std::unique_ptr<connectivity::OSQLParseNode>' with nullptr, just use default constructor [loplugin:simplifyconstruct]
,m_pParseTree(nullptr)
^~~~~~~~~~~~~~~~~~~~~
from another patch to calm down clang Jenkins
Change-Id: Ia8304b7baedbce760a6e01ea154c5ff3cd19cbd4
Reviewed-on: https://gerrit.libreoffice.org/83595
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
Tested-by: Julien Nabet <serval2412@yahoo.fr>
|
|
Change-Id: Iddbd3256aabe9552472b55d3d9b88a3769698de9
Reviewed-on: https://gerrit.libreoffice.org/83576
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
Tested-by: Julien Nabet <serval2412@yahoo.fr>
|
|
...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>
|
|
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>
|
|
found by the simple expidient of putting asserts in
the resize routine. Where an explicit const size is used,
I started with 32 and kept doubling until that site
did not need resizing anymore.
Change-Id: I998787edc940d0a3ba23b5ac37131ab9ecd300f4
Reviewed-on: https://gerrit.libreoffice.org/81138
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
It started out as a wrapper around character literals, but has by now become a
wrapper around arbitrary single characters. Besides updating the documentation,
this change is a mechanical
for i in $(git grep -Fl OUStringLiteral1); do sed -i -e s/OUStringLiteral1/OUStringChar/g "$i"; done
Change-Id: I1b9eaa4b3fbc9025ce4a4bffea3db1c16188b76f
Reviewed-on: https://gerrit.libreoffice.org/80892
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
and extend O*StringView to have a constructor that takes a pointer and a
length
Change-Id: I6120e96280f030757e855a6596efdae438b7e1e8
Reviewed-on: https://gerrit.libreoffice.org/80872
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
look for OUStringBuffer append sequences that can be turned
into creating an OUString with + operations
Change-Id: Ica840dc096000307b4a105fb4d9ec7588a15ade6
Reviewed-on: https://gerrit.libreoffice.org/80809
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
which defeat the *StringConcat optimisation.
Also make StringConcat conversions treat a nullptr as an empty string,
to match the O*String(char*) constructors.
Change-Id: If45f5b4b6a535c97bfeeacd9ec472a7603a52e5b
Reviewed-on: https://gerrit.libreoffice.org/80724
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
mostly so that my stringadd loplugin can point out places to improve
Change-Id: I9920ee1c99cdb6b811ba67ff9d8e32aa261884b5
Reviewed-on: https://gerrit.libreoffice.org/80618
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Change-Id: I3424e17cfdfb563fdc5882942031deafae8689fe
Reviewed-on: https://gerrit.libreoffice.org/78678
Tested-by: Jenkins
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
|
|
To complete this:
https://gerrit.libreoffice.org/#/c/78312/
This is a massive replace for
".." instead of "..." between words.
It passed "make check" on Linux.
Change-Id: I144d8061fca9f545c762941551e59dffdd3650e8
Reviewed-on: https://gerrit.libreoffice.org/78357
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
Tested-by: Jenkins
|
|
Change-Id: Id5f8c6a5c8ef7494c8ccd3268eab3fe65d027cb3
Reviewed-on: https://gerrit.libreoffice.org/78054
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
Tested-by: Julien Nabet <serval2412@yahoo.fr>
|
|
Change-Id: I98c29cbdb701f00fa73f9c8107fb4349b48a564e
Reviewed-on: https://gerrit.libreoffice.org/78015
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
Change-Id: Ia474439d4e35009ec0941b122653a649692aead7
Reviewed-on: https://gerrit.libreoffice.org/77943
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
Change-Id: I7fefdc7ca23a2f505944288c30c820ef70da14ae
Reviewed-on: https://gerrit.libreoffice.org/77942
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
...which obsoleted RFC 2396. Notable changes are that the distinction between
hierarchical and opaque URIs has been dropped, and that the relative URI
resolution specification has been made more rigid.
As a consequence, various features of css.uri entities have changed:
* XUriReference.isHierarchical is obsolete and deprecated.
* The behavior of XUriReference.hasAuthority, XUriReference.getAuthority,
XUriReference.getPath, XUriReference.hasRelativePath,
XUriReference.getPathSegmentCount, XUriReference.getPathSegment,
XUriReference.hasQuery, and XUriReference.getQuery has been made consistent
for all URIs, no matter whether they were considered hierarchical or opaque in
the past.
* The behavior of XUriReferenceFactory.makeAbsolute and
XUriReferenceFactory.makeRelative has been changed to match the RFC 3986
reference resolution specification. The XUriReferenceFactory.makeAbsolulte
parameter processSpecialBaseSegments has been renamed to
processAdditionalSpecialSegments, as per the updated specification it now
controls treatment of special segments in the given uriReference, in addition
to special segments in the given baseUriReference. (Renaming UNOIDL interface
method parameters is technically an incompatible change, but the benefits of
improved clarity presumably outweigh any potential drawbacks in this case.)
The implementation in stoc has been adapted, and various call sites have been
adapted to the deprecated XUriReference.isHierarchical semantics.
Change-Id: Ic6e00fdbce5abef70d75ec2f753d22fefe361457
Reviewed-on: https://gerrit.libreoffice.org/77861
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
Change-Id: Ieb0116321bbddd804db6d1789ea3521c5b220840
Reviewed-on: https://gerrit.libreoffice.org/77807
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
`absolute` has the same value as `uriReference` here, so replace it with nullptr
as is done in all the other cases where those values are the same.
Change-Id: I81e2842921b99f9c9a4c847a46e74300b5e527ab
Reviewed-on: https://gerrit.libreoffice.org/77720
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
Change-Id: I94d938c60074f74996cce4eb99183c5372e5c1de
Reviewed-on: https://gerrit.libreoffice.org/77699
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
Change-Id: Ie0dd5b4d0b994ce6e1687bdb21749cb6cafc2366
Reviewed-on: https://gerrit.libreoffice.org/77700
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
in sfx2, stoc
Change-Id: I7138f702317d0e693438216732bf181f1972cdc1
Reviewed-on: https://gerrit.libreoffice.org/77648
Tested-by: Jenkins
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
|
|
"/g" was missing, and "http:g" had an extra "." (consistently applied to all
three occurrences of "http", but for unclear reasons).
(<https://www.rfc-editor.org/errata/eid452> claims that "?y" is an invalid
example that should be removed, but our algorithm does resolve it to the value
<http://a/b/c/?y> originally given in RFC 2396, so lets keep it for now.)
Change-Id: I3187abd36135723bd13293367a6cb6c06ca70b90
Reviewed-on: https://gerrit.libreoffice.org/77602
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
...which had gone missing with d2097ad456b4626dd6972e015489ce3d22eb1872
"gbuildize stoc". Required lots of loplugin warning fixes now.
Change-Id: I411034f462846557f72ea1e9a91cd88517d2944c
Reviewed-on: https://gerrit.libreoffice.org/77579
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
* Use const methods of Sequence
* Get rid of extra loop over localSeq
* Simplify default keys insert condition
Change-Id: I112c0a53d3ebfc2ff54a4ac904e6e112beaf3cdd
Reviewed-on: https://gerrit.libreoffice.org/77472
Tested-by: Jenkins
Reviewed-by: Arkadiy Illarionov <qarkai@gmail.com>
|
|
Change-Id: I473a8eec9cbf6d44b55ffd6f2233bf39cf6217da
Reviewed-on: https://gerrit.libreoffice.org/77528
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
...to avoid UB when fVal was cast to nRet *before* checking that fVal actually
fit into the bounds, and to avoid Clang 10
-Werror,-Wimplicit-int-float-conversion when comparing fVal against
SAL_MAX_INT64 ("implicit conversion from 'const sal_Int64' (aka 'const long') to
'double' changes value from 9223372036854775807 to 9223372036854775808")
Change-Id: I9e2f6c97309609d9ec2455d4ecf9c341d85c1680
Reviewed-on: https://gerrit.libreoffice.org/77430
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
(cf. f2b0299972730989c46949d6101c7c346fc01971 "#97095# MS Visual C++ unsigned
__int64 to double missing"), assuming that our baseline MSVC is capable of that
by now.
Replace DOUBLE_SAL_UINT64_MAX with double(SAL_MAX_UINT64) and replace
unsigned_int64_to_double(X) with either X or static_cast<double>(X), matching
respective context.
Change-Id: Ia1e1daff5cbcb545738615fad541082810d7a46b
Reviewed-on: https://gerrit.libreoffice.org/77414
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
Change-Id: Ic1c18f1eb7db7b25cc1b276b8786630bd1d68929
Reviewed-on: https://gerrit.libreoffice.org/77397
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
Change-Id: Ia44a9dd214b5b09ed6f9c39b8057c41ae03897f1
Reviewed-on: https://gerrit.libreoffice.org/77285
Tested-by: Jenkins
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
|
|
"Inherting"
Change-Id: Ib9b1fcfd9ef585149de5018ce650707c71d412c8
Reviewed-on: https://gerrit.libreoffice.org/77127
Tested-by: Jenkins
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
|
|
Change-Id: Id739d5ff815d3bb1db48e9b1c2b3f739e3f11dfd
Reviewed-on: https://gerrit.libreoffice.org/76644
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
Use range-based loops, STL and comphelper functions
Change-Id: I612d36abcc09a91c60f7212de6747a1a1bdcfc69
Reviewed-on: https://gerrit.libreoffice.org/76056
Tested-by: Jenkins
Reviewed-by: Arkadiy Illarionov <qarkai@gmail.com>
|
|
Change-Id: Id0f0332d5d66c0bce309643bf42059b9bdc7d448
Reviewed-on: https://gerrit.libreoffice.org/75997
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Change-Id: I356e574e28338f6fddc6932b4e41a461d851406d
Reviewed-on: https://gerrit.libreoffice.org/74141
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
...following up on 1453c2c8f13bac64ecd1981af7cebf1c421808ac "prefer vector::data
to &vector[0]"
Change-Id: I7c113747d92d144a521d49b89384dd8bf1215c01
Reviewed-on: https://gerrit.libreoffice.org/72765
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
|
|
Found with bin/find-unneeded-includes
Only removal proposals are dealt with here.
Change-Id: I3c1b091d30449243faec3f875e6f0ac6d8b34259
Reviewed-on: https://gerrit.libreoffice.org/72214
Tested-by: Jenkins
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
|
|
Similar to clang-tidy readability-container-size-empty
Change-Id: Icabd773f3b924d465b33e8581175f1fcf70c282e
Reviewed-on: https://gerrit.libreoffice.org/71704
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|