summaryrefslogtreecommitdiff
path: root/o3tl
AgeCommit message (Collapse)AuthorFilesLines
2017-10-26Add test for o3tl::saturating_addStephan Bergmann2-0/+120
Change-Id: I19bb1d566bd80f859810b4023d965c8fd80b98f2
2017-10-25improve o3tl::enumarray const-nessNoel Grandin2-0/+49
Change-Id: I7b0d10b024edf604a7dea0e3b1399073f4bcba92 Reviewed-on: https://gerrit.libreoffice.org/43773 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-10-23loplugin:includeform: o3tlStephan Bergmann6-18/+18
Change-Id: I3cf4cda744148c966d0686310fef5dab6d3a3b35
2017-09-06const correctness in o3tl::array_viewNoel Grandin1-3/+9
Change-Id: I44c1ace97ae44069c5a0c6a247aa8a0b49896ad3 Reviewed-on: https://gerrit.libreoffice.org/41985 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-07-31loplugin:oncevarNoel Grandin1-3/+3
extend oncevar to any POD type Change-Id: Ia98ee0a67f183e40fb0c38477760124b2c411dc0 Reviewed-on: https://gerrit.libreoffice.org/40564 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-06-17create o3tl::array_viewNoel Grandin2-0/+80
A very basic implementation of the proposed std::array_view, similar to clang's llvm::ArrayRef. Mostly cribbed from the string_view implementation :-) Use it for the SfxDispatcher::setSlotFilter function Change-Id: Ife7e4971741b41827e145787899872c9b2bea82b Reviewed-on: https://gerrit.libreoffice.org/38817 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-04-25tools: svstream.hxx needs only errcode.hxx & not errinf.hxxChris Sherlock1-0/+1
Change-Id: Ia28e35ae5af4f601e9a586a3deffbcd61702b0ca Reviewed-on: https://gerrit.libreoffice.org/36896 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com>
2017-04-21gbuild: Remove MSVC 2013 legacy codeDavid Ostrovsky1-1/+0
Uwinapi is discontinued. Change-Id: I063b4d0d8fab2d60de168e960a63b8181158ac01 Reviewed-on: https://gerrit.libreoffice.org/23198 Reviewed-by: David Ostrovsky <david@ostrovsky.org> Tested-by: David Ostrovsky <david@ostrovsky.org>
2017-04-07Introduce o3tl::string_view.hxx approximation of C++17 <string_view>Stephan Bergmann2-0/+213
...and use it in configmgr/source/writemodfile.hxx Change-Id: Ie683dc21010ed45cc454ff89bea0376994b351f2 Reviewed-on: https://gerrit.libreoffice.org/36270 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2017-03-31Sort lines lexicographicallyStephan Bergmann1-2/+2
Change-Id: I40cb900331493f7cdd13ceca1d5aec93f0c81aca
2017-03-25Fix typosAndrea Gelmini1-1/+1
Change-Id: I14dca0d55c09187690dc1d94936c40b890ca5cea Reviewed-on: https://gerrit.libreoffice.org/35637 Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Julien Nabet <serval2412@yahoo.fr>
2017-03-14fix typo: alreay --> already dennisroczek1-2/+2
Change-Id: Iabb8588a2547c925c2c959f3b4831c89935a9529 Reviewed-on: https://gerrit.libreoffice.org/35133 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-02-01loplugin:useuniqueptr extend to check local varsNoel Grandin1-84/+66
just the simple and obvious case for now, of a local var being allocated and deleted inside a single local block, and the delete happening at the end of the block Change-Id: I3a7a094da543debdcd2374737c2ecff91d644625 Reviewed-on: https://gerrit.libreoffice.org/33749 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-01-24coverity#1399266 Uncaught exceptionCaolán McNamara1-9/+5
Change-Id: I1066fda2258e6acbbbad23256f815975564e5e61
2016-09-12coverity#1371178 Missing move assignment operatorCaolán McNamara2-0/+28
Change-Id: Ib7df699269bcacd5dbf64662c47b538aee9235a5
2016-06-03CppunitTest_sal_osl_file: fix loplugin:cppunitassertequals warningsMiklos Vajna1-9/+9
Change-Id: Ib0594ba236284aa69d180fb72ce60435b679ea05 Reviewed-on: https://gerrit.libreoffice.org/25852 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org>
2016-06-02CppunitTest_o3tl_tests: fix loplugin:cppunitassertequals warnings in ...Miklos Vajna1-56/+56
... sorted_vector Change-Id: Ie6c5f0e187228e2cf7769c62c86ff3cba80ab6ce Reviewed-on: https://gerrit.libreoffice.org/25804 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org>
2016-05-27CppunitTest_o3tl_tests: fix loplugin:cppunitassertequals warnings in ...Miklos Vajna3-27/+36
... cow_wrapper and vector_pool Change-Id: I1f224a6bd933592dcb34defd5ad5c480d82346cb Reviewed-on: https://gerrit.libreoffice.org/25531 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org>
2016-04-30Fix typosAndrea Gelmini1-1/+1
Change-Id: Id81b16ff26283611f0b84929d831c827f847ab73 Reviewed-on: https://gerrit.libreoffice.org/24317 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
2016-02-09Remove excess newlinesChris Sherlock2-3/+0
A ridiculously fast way of doing this is: for i in $(pcregrep -l -M -r --include='.*[hc]xx$' \ --exclude-dir=workdir --exclude-dir=instdir '^ {3,}' .) do perl -0777 -i -pe 's/^ {3,}/ /gm' $i done Change-Id: Iebb93eccbee9e4fc5c4380474ba595858a27ac2c Reviewed-on: https://gerrit.libreoffice.org/22224 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com>
2016-01-29remove unused o3tl::rangeDavid Tardon2-227/+0
Change-Id: I080f4f2cb15d25ecf5545300da422957f24e3f9b
2016-01-10Fix typosAndrea Gelmini1-1/+1
Change-Id: I9a5940027423ff0791fa7da0b79b617412ce6b86 Reviewed-on: https://gerrit.libreoffice.org/21209 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
2015-09-15Fix binary ops with two o3tl::type_flags<E>::Wrap paramsStephan Bergmann1-0/+4
(the original ones would never have been picked due to how template argument deduction works) Change-Id: I5a08c763d721d8e11b5a10af2344a6a24bb0b9b2 Reviewed-on: https://gerrit.libreoffice.org/18583 Reviewed-by: Stephan Bergmann <sbergman@redhat.com> Tested-by: Stephan Bergmann <sbergman@redhat.com>
2015-09-01coverity#1321598 Resource leak in objectCaolán McNamara1-3/+2
and coverity#1321597 Resource leak in object Change-Id: I6e9e517a394bea60c1f0550b17bacd653eee5cbc
2015-08-30loplugin:implicitboolconversionStephan Bergmann3-17/+17
Change-Id: Id4561abb96ee8244d4c0b0c9dfce0e2cab1d8b85
2015-08-29o3tl: add another unit test to cow_wrapperDaniel Robertson3-0/+190
Add unit tests to cow_wrapper for the move ctor and move assignment. Change-Id: I82a5886ca7ae110985c7202125699cf95b6466d8 Reviewed-on: https://gerrit.libreoffice.org/18108 Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de> Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
2015-08-26Revert "create a macro to tidy up the declaration sites of ↵Noel Grandin1-1/+4
o3tl::typed_flags_set" sberg did not like this macro, let's see if I can find a better solution. This reverts commit e51fa143587d018b75db08e60cf27ff932b1cf8d.
2015-08-17o3tl: rename compat_functional headerThorsten Behrens1-3/+4
After the cleanup, the stuff there really stands on its own (and the remaining usage of select1st/2nd is more descriptive than lambdas). Change-Id: I0aba131d5dc550189f8130d167dc94167e404540 Reviewed-on: https://gerrit.libreoffice.org/17806 Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de> Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
2015-07-24LRU map (cache) implementation to o3tl + testsTomaž Vajngerl2-0/+240
Change-Id: I6b1a39918e6c8c67712be2c8e9907266dcfefedb
2015-07-15create a macro to tidy up the declaration sites of o3tl::typed_flags_setNoel Grandin1-4/+1
Change-Id: Ifb8fd4fd5128188420f1dfda6b6f695160d5e77a Reviewed-on: https://gerrit.libreoffice.org/15865 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de> Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
2015-06-11cppcheck: noExplicitConstructorCaolán McNamara1-1/+1
Change-Id: Id6291335945a8f10cef3afd1a2b3bae65fdf4562
2015-06-08loplugin:cstylecast: deal with remaining pointer castsStephan Bergmann1-1/+1
Change-Id: Ic29f424f5eb579ab95907c110529cdc9002443e1
2014-11-07fdo#84938: replace MOUSE_ modifier constants with enumNoel Grandin1-2/+0
and make the two categories of constants non-overlapping, we really don't need to risk confusion in order to save 6 bits in a data structure like this. Change-Id: I2251195d8e45ed04e2a89e47ae9c3e52cf0475c0
2014-11-07bug in typed flagsNoel Grandin1-0/+3
/home/noel/libo2/o3tl/qa/test-typed_flags.cxx:50:52: error: invalid argument type 'typename o3tl::typed_flags<ConfigurationChangedHint>::Wrap' to unary expression ConfigurationChangedHint nHint2 = nHint & ~(ConfigurationChangedHint::ONE | ConfigurationChangedHint::TWO); ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 1 error generated. Change-Id: Ia03e1e7d6afff0bdbb87e82ec076d5ffb820afb2
2014-10-14need explicit bool conversions hereNoel Grandin1-2/+2
to make some tinderboxes happy Change-Id: I136895674cec8eda874acda0bf5c7a96b3a22778
2014-10-14fixes and tests for o3tl::typed_flagsNoel Grandin2-0/+64
create test suite for typed_flags template. fix the operator&= and operator|= definitions Signed-off-by: Stephan Bergmann <sbergman@redhat.com> Conflicts: include/o3tl/typed_flags_set.hxx Change-Id: I1df9ae197889af98a2fd76ff2bc07756c7b14ced
2014-10-08We should know what our name isTor Lillqvist1-1/+1
Change-Id: I4e4d9c9aea5bb9387dbb2e69d94c48f4988c3346
2014-10-06It is "template library", not "tools"Tor Lillqvist1-1/+1
Change-Id: I5ca7b0a0374a9ed0090413e8c6045e5d13097301
2014-10-06Add guess at what o3tl meansTor Lillqvist1-0/+2
Change-Id: I69c8ce10140e92714e9d5c4b4173ade59d36be08
2014-09-24Remove o3tl/heap_ptr.hxx, use std::unique_ptr insteadStephan Bergmann3-161/+0
Change-Id: Iac70c9be13892a36bfb5975f62e5345b88d4f144
2014-09-15Mark o3tl::heap_ptr as SAL_WARN_UNUSEDStephan Bergmann1-0/+1
...to make it more straightforward to fix blunder as in a88b2d841856026ea1a0539d670e07fafd296c6e "Resolves: fdo#81039 crash on adding new macro library." Conceivably, instances of heap_ptr could legitimately be created only for ctor/ dtor effect, but then again uses of heap_ptr should arguably be replaced with std::unique_ptr anyway. Change-Id: I9c765b8d265f3c26d459ec276e335eeebc8fee91
2014-05-22Fix memory leaks in test codeStephan Bergmann1-0/+11
Change-Id: I0dbb2546f1e776ebf95b61c16ebedbce0ead4c7f
2014-05-15Resolves fdo#70681: fixincludeguards.pl: all that's leftThomas Arnhold1-3/+3
Change-Id: I3e51a62710bb46c8255fd228d41d9300c90a1fb5 Reviewed-on: https://gerrit.libreoffice.org/9360 Reviewed-by: Thomas Arnhold <thomas@arnhold.org> Tested-by: Thomas Arnhold <thomas@arnhold.org>
2014-05-02coverity#1209778 & coverity#1209777 Resource leakChris Sherlock1-0/+2
Have testBasics_FindPtr() cleanup after itself by deleting p2 and p4. Change-Id: I88b5efd25941d135b743f759a8f27c1cdbcb43c0
2014-05-02coverity#1209779 & coverity#1209780 Resource leakChris Sherlock1-0/+2
Have the testBasics() function clean up after itself - delete p2 and p4 at the end of the function. Change-Id: Ib0c732e1962da94fde0e0da307f610dd36f49eda
2014-04-28prefer makefile-gmake-modeTakeshi Abe1-1/+1
Change-Id: I9cc9bfbddd3a90e00eee3e674994e5d6207f9034
2014-02-25Remove visual noise from o3tlAlexander Wilms2-2/+2
Change-Id: I15bd49dfa24b5eb260d442f15947788b41d000d1 Reviewed-on: https://gerrit.libreoffice.org/8284 Reviewed-by: Thorsten Behrens <thb@documentfoundation.org> Tested-by: Thorsten Behrens <thb@documentfoundation.org>
2014-02-23Remove unneccessary commentsAlexander Wilms4-5/+5
Change-Id: I939160ae72fecbe3d4a60ce755730bd4c38497fb Reviewed-on: https://gerrit.libreoffice.org/8182 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2013-06-03re-base on ALv2 code. Includes:Michael Meeks2-42/+24
Patches contributed by Mathias Bauer gnumake4 work variously http://svn.apache.org/viewvc?view=revision&revision=1394707 http://svn.apache.org/viewvc?view=revision&revision=1394326 http://svn.apache.org/viewvc?view=revision&revision=1397337 http://svn.apache.org/viewvc?view=revision&revision=1397315 http://svn.apache.org/viewvc?view=revision&revision=1396797 Patches contributed by Andre Fischer Fixed getcsym.awk to handle #-comments that contain special regexp chars. http://svn.apache.org/viewvc?view=revision&revision=1230971 118778: Added ADDITIONAL_REPOSITORIES environment variable and its automatic setup in configure. http://svn.apache.org/viewvc?view=revision&revision=1232004 118160: Added external CoinMP library. http://svn.apache.org/viewvc?view=revision&revision=1233909 Patches contributed by Herbert Duerr #i119168# use generic LICENSE file for langpacks and sdks http://svn.apache.org/viewvc?view=revision&revision=1310178 macosxotoolhelper: need to quote perl regexp if it may contain regexp metachars http://svn.apache.org/viewvc?view=revision&revision=1183367 allow gbuild with empty sysroot on linux http://svn.apache.org/viewvc?view=revision&revision=1179186 Patches contributed by Ingo Schmidt native373: #164472# improvements for msi database http://svn.apache.org/viewvc?view=revision&revision=1167540 http://svn.apache.org/viewvc?view=revision&revision=1167539 Patches contributed by Jurgen Schmidt adapt setup package scripts to handle special DS_Store file for developer snapshot builds http://svn.apache.org/viewvc?view=revision&revision=1232430 imported patch extensions_i117681.patch http://svn.apache.org/viewvc?view=revision&revision=1172102 Patches contributed by Michael Stahl gbuild: RepositoryFixes.mk should be optional http://svn.apache.org/viewvc?view=revision&revision=1166123 xslt filter: remove the FLA horror wordml import filter: replace FLA usage with plain XSLT http://svn.apache.org/viewvc?view=revision&revision=1363727 Patch contributed by Oliver-Rainer Wittmann i#88652: applied patch, remove unicows deps http://svn.apache.org/viewvc?view=revision&revision=1177585 Remove lots of OS2 conditionals, re-extract Rhino Java, unwind cppunit pieces, cleanup Mac image bits, remove coin-mp and re-package lpsolve, Oxygen & Crystal, fixup qstart bits, expand MPLv2 subset checking. Change-Id: Iad5c8a76399620b892671633c0d8c29996db3564
2013-05-08coverity#983036/37/38: Resource leakJulien Nabet1-0/+3
Change-Id: I8a2c079a60cc06ca82d9f516cf009359a0c083a7 Reviewed-on: https://gerrit.libreoffice.org/3819 Reviewed-by: Noel Power <noel.power@suse.com> Tested-by: Noel Power <noel.power@suse.com>