summaryrefslogtreecommitdiffstats
path: root/tests/auto/corelib/tools/qbytearray
Commit message (Collapse)AuthorAgeFilesLines
* Move text-related code out of corelib/tools/ to corelib/text/Edward Welbourne2019-07-107-3362/+0
| | | | | | | | This includes byte array, string, char, unicode, locale, collation and regular expressions. Change-Id: I8b125fa52c8c513eb57a0f1298b91910e5a0d786 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* QByteArray autotest: code tidiesGiuseppe D'Angelo2019-06-231-6/+6
| | | | | | | | | | Suppress a few warnings raised by GCC 9. Change-Id: Ic52dc9c85e447ee0f54ef8310a7fcd41d6e09304 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Remove handling of missing very old compiler feature checkAllan Sandfeld Jensen2019-04-061-4/+0
| | | | | | | | | | | Removes handling of missing Q_COMPILER_NULLPTR, Q_COMPILER_AUTODECL, Q_COMPILER_LAMBDA, Q_COMPILER_VARIADIC_MACROS and Q_COMPILER_AUTO_FUNCTION. We haven't supported any compilers without these for a long time. Change-Id: I3df88206516a25763e2c28b083733780f35a8764 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Replace qMove with std::moveAllan Sandfeld Jensen2019-04-061-8/+8
| | | | | | Change-Id: I67df3ae6b5db0a158f86e75b99f422bd13853bc9 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* Avoid copying QByteArray created via fromRawData in toDoubleVolker Hilsheimer2019-03-091-0/+3
| | | | | | | | | | | qt_asciiToDouble accepts a length parameter, so we can just pass that through. No need for explicitly null-terminating, which is where the copy of the data would be made. Change-Id: I4e7921541f03295a2fae6171b35157084ff3ed8c Fixes: QTBUG-65748 Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* QByteArray: toInt() and toDouble() ignore surrounding whitespacesAndre Hartmann2018-07-071-0/+44
| | | | | | | | | | | | | [ChangeLog][QtCore][QByteArray] QByteArray::toInt(), QByteArray::toDouble() and the other number conversion functions now ignore leading and trailing whitespaces, as their QString counterparts already did. For consistency reasons, the same behavior was added to qEnvironmentVariableIntValue() also. Task-number: QTBUG-66187 Change-Id: I8b5e478ea8577b811d969286ea9e269f539c1ea4 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* QByteArray: implement qstricmp with SSE 4.1Thiago Macieira2018-06-271-0/+6
| | | | | | | Using SSE 4.1 because of the need for PMINUB. Change-Id: Ib48364abee9f464c96c6fffd152ebd3f8ea7fe94 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* QByteArray: add compare() with case sensitivity optionsThiago Macieira2018-06-221-3/+29
| | | | | | | | | | | | | Need to do the same for startsWith() and endsWith(). indexOf() is a lot harder. [ChangeLog][QtCore][QByteArray] Added compare(), which takes Qt::CaseSensitivity as one of the parameters. This function is more efficient than using toLower() or toUpper() and then comparing. Change-Id: Ib48364abee9f464c96c6fffd152e69bde4194df7 Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io> Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
* QByteArray: Add functions isUpper() and isLower() for Latin1 byte arraysAndre Hartmann2018-02-171-0/+47
| | | | | | | | | [ChangeLog][QtCore][QByteArray] Added QByteArray::isUpper() and QByteArray::isLower() to check if a byte array contains only uppercase or only lowercase Latin1 letters. Change-Id: I7ab3c775bc714138d4be259ac6fa2cfc70467ed4 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Merge remote-tracking branch 'origin/5.9' into 5.11Liang Qi2018-02-141-1/+1
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: .qmake.conf src/corelib/animation/qvariantanimation.cpp src/corelib/global/qglobal.cpp src/corelib/global/qlogging.cpp src/corelib/io/qprocess_win.cpp src/corelib/json/qjsonarray.cpp src/corelib/tools/qsimd_p.h src/corelib/tools/qtimezoneprivate_p.h src/corelib/xml/qxmlstream_p.h src/gui/kernel/qsimpledrag.cpp src/gui/kernel/qsimpledrag_p.h src/plugins/generic/generic.pro src/plugins/platforms/cocoa/qcocoamenu.mm src/widgets/styles/qmacstyle_mac.mm tests/auto/concurrent/qtconcurrentmap/BLACKLIST tests/auto/corelib/io/qfileinfo/tst_qfileinfo.cpp tests/auto/corelib/tools/qdatetime/tst_qdatetime.cpp tests/auto/gui/kernel/qwindow/BLACKLIST tests/auto/widgets/dialogs/qmessagebox/BLACKLIST Change-Id: I508d686cf20f7f8cc6a7119b9bc7c3bbb505c58e
| * Support for Q_OS_ANDROID_EMBEDDED and android-embedded build flagsOtto Ryynänen2018-01-201-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | The Embedded Android build (Boot to Qt Android injection) is defined by having both Q_OS_ANDROID and Q_OS_ANDROID_EMBEDDED flags defined, as well as having Qt config android-embedded. This commit enables the possibility to build embedded Android builds. (i.e. Qt build for Android baselayer only, without JNI) Change-Id: I8406e959fdf1c8d9efebbbe53f1a391fa25f336a Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io> Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
* | Remove references to obsolete platformsJake Petroules2017-11-051-6/+0
|/ | | | | | | | | | | | | | ultrix and reliant have not seen a release since 1995. dgux not since 2001. bsdi not since 2003. irix not since 2006. osf not since 2010. dynix... unclear, but no later than 2002. symbian needs no mention. All considered obsolete, all gone. sco and unixware are effectively obsolete. Remove them until someone expresses a real need. Change-Id: Ia3d9d370016adce9213ae5ad0ef965ef8de2a3ff Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Fix some MSVC warnings in testsFriedemann Kleint2017-06-281-1/+1
| | | | | | | | | | | | tst_qvariant.cpp(80): warning C4309: 'initializing': truncation of constant value tst_qvariant.cpp(4635): warning C4309: 'initializing': truncation of constant value tst_qbytearray.cpp(1438): warning C4267: 'argument': conversion from 'size_t' to 'uint', possible loss of data tst_qbytearray.cpp(1440): warning C4267: 'argument': conversion from 'size_t' to 'uint', possible loss of data http2srv.cpp(64): warning C4018: '<=': signed/unsigned mismatch tst_qinputdialog.cpp(352): warning C4804: '<=': unsafe use of type 'bool' in operation Change-Id: Id012d88b7b20c5c9f128f2ef53753cc1d479f358 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Extend qChecksum calculationLars Schmertmann2016-12-251-0/+30
| | | | | | | | | | | | | | ISO 14443-3 is for nfc communication and uses 2 different checksums. The existing one is from ISO 3309 and the other one is from ITU-V.41. Both are needed to implement an own transport layer defined in ISO 14443-4 to allow nfc commands with a length above 250 byte independent from the smartphone. This change will avoid code duplication in QNearFieldTarget. The private function qNfcChecksum is a copy of qChecksum. Change-Id: I790ffec8e2ea46f88b2db6f48b64fdcb140e7b70 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* QByteArray: Overload toHex() with separator characterAndre Hartmann2016-12-241-2/+45
| | | | | | | | | | | | | The separator character is inserted in the resulting array after every byte and is useful for MAC address output like 01:23:45:ab:cd:ef, Hash fingerprints, or low level data debug output. [ChangeLog][QtCore][QByteArray] Added toHex() overload to insert a separator character between the hex bytes. Change-Id: Ibe436094badc02f3ade7751aa8b5d690599941d4 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Merge remote-tracking branch 'origin/5.7' into 5.8Liang Qi2016-09-051-3/+11
|\ | | | | | | | | | | | | | | Conflicts: mkspecs/features/qt_common.prf src/plugins/platforms/windows/qwindowsdialoghelpers.cpp Change-Id: I03b92b6b89ecc5a8db7c95f04ebb92ed198098a8
| * Merge remote-tracking branch 'origin/5.6' into 5.7Liang Qi2016-09-051-3/+11
| |\ | | | | | | | | | | | | | | | | | | Conflicts: tests/auto/testlib/selftests/generate_expected_output.py Change-Id: If856162abf9a24ae2c9946d336a7d1da03520fa7
| | * qstrncpy: don't call strncpy_s with invalid parametersMarc Mutz2016-09-031-3/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | According to https://msdn.microsoft.com/en-us/library/5dae5d43.aspx, strncpy_s' second argument must not be 0: > If strDest or strSource is NULL, *or numberOfElements is 0*, the > invalid parameter handler is invoked. Move the existing check for len > 0 up to protect the strncpy_s call, too. Change-Id: I70d339ea60d4b76f3038b2e4e4756f6590a9bd31 Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | | Merge remote-tracking branch 'origin/5.7' into devLiang Qi2016-06-131-18/+70
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: config_help.txt configure mkspecs/features/uikit/sdk.prf src/corelib/global/qhooks.cpp src/corelib/io/qfilesystemwatcher.cpp src/corelib/io/qlockfile_unix.cpp src/corelib/tools/qalgorithms.h src/gui/kernel/qwindowsysteminterface.h src/gui/text/qtextdocument_p.cpp src/network/access/access.pri src/network/access/qnetworkaccessmanager.cpp src/network/access/qnetworkreplynsurlconnectionimpl.mm src/src.pro src/testlib/qtestcase.cpp src/widgets/kernel/qwidgetbackingstore_p.h src/widgets/styles/qwindowscestyle.cpp src/widgets/styles/qwindowsmobilestyle.cpp tests/auto/corelib/io/qdiriterator/qdiriterator.pro tests/auto/corelib/io/qfileinfo/qfileinfo.pro tests/auto/gui/kernel/qwindow/BLACKLIST tests/auto/widgets/dialogs/qfilesystemmodel/tst_qfilesystemmodel.cpp tools/configure/configureapp.cpp Change-Id: Ibf7fb9c8cf263a810ade82f821345d0725c57c67
| * | Replace qAllocMore with a pair of more useful functionsThiago Macieira2016-06-091-18/+70
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The first is "exact", not "more": qCalculateBlockSize. It ensures that there's no overflow in multiplying, adding the header size or when converting back to an int. The second is the replacement for qAllocMore: it calculates the block size like the first, but increases the block size to accommodate future appends. The number of elements that fit in the block is also returned. Task-number: QTBUG-41230 Change-Id: I52dd43c12685407bb9a6ffff13f5da09f816e667 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* | | Merge remote-tracking branch 'origin/5.7' into devLiang Qi2016-04-051-1/+1
|\| | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: examples/corelib/ipc/ipc.pro src/plugins/platforms/xcb/qxcbbackingstore.cpp tests/auto/corelib/tools/qcommandlineparser/tst_qcommandlineparser.cpp Change-Id: Ia006e10ff1732fe78f90138c41f05b59b49486cf
| * | Remove the traces of the discontinued android-no-sdk platformEirik Aavitsland2016-03-301-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | Cleaning out the workarounds for the discontinued "Embedded Android" platform of Boot2Qt. Change-Id: I0ff9d770e82a43457fb7e5da0428f4597ead4038 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
* | | QtCore: Remove Windows CE.Friedemann Kleint2016-03-301-13/+1
|/ / | | | | | | | | | | | | | | | | Remove QSysInfo::WV_CE_5/6 enumeration values, #ifdef sections for Q_OS_WINCE and wince .pro file clauses in library, examples and tests. Task-number: QTBUG-51673 Change-Id: Ib63463445f3a26e04d018b193e4655030002f5f9 Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
* | Add Intel copyright to files that Intel has had non-trivial contributionThiago Macieira2016-01-211-0/+1
| | | | | | | | | | | | | | | | | | I wrote a script to help find the files, but I reviewed the contributions manually to be sure I wasn't claiming copyright for search & replace, adding Q_DECL_NOTHROW or adding "We mean it" headers. Change-Id: I7a9e11d7b64a4cc78e24ffff142b506368fc8842 Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
* | Updated license headersJani Heikkinen2016-01-212-34/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | From Qt 5.7 -> tools & applications are lisenced under GPL v3 with some exceptions, see http://blog.qt.io/blog/2016/01/13/new-agreement-with-the-kde-free-qt-foundation/ Updated license headers to use new GPL-EXCEPT header instead of LGPL21 one (in those files which will be under GPL 3 with exceptions) Change-Id: I42a473ddc97101492a60b9287d90979d9eb35ae1 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
* | tests/auto/corelib: Remove some placeholder formatting.Friedemann Kleint2015-10-221-4/+4
| | | | | | | | | | | | | | | | Use QByteArray/QString addition instead in loops and for test row names. Change-Id: Ieffb429efdc14aa5932b3fcdef5a18e13a62d35f Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@theqtcompany.com>
* | Tests: Fix single-character string literals.Friedemann Kleint2015-10-131-4/+4
| | | | | | | | | | | | | | Use character literals where applicable. Change-Id: I1a026c320079ee5ca6f70be835d5a541deee2dd1 Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
* | Tests: Remove CONFIG += parallel_test.Friedemann Kleint2015-09-051-1/+1
| | | | | | | | | | | | | | The keyword no longer has a meaning for the new CI. Change-Id: Ibcea4c7a82fb7f982cf4569fdff19f82066543d1 Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
* | Remove QT_DISABLE_DEPRECATED_BEFORE=0 from tests not using deprecated API.Friedemann Kleint2015-09-011-1/+0
| | | | | | | | | | Change-Id: I1955320e7639760b4383a53f37a506c8055933ef Reviewed-by: Liang Qi <liang.qi@theqtcompany.com>
* | QByteArray: Add append/prepend/insert overloadKevin Funk2015-08-271-10/+25
|/ | | | | | | | | | Use-case is fast insertion of copies of a character, avoiding any temporary heap allocations Change-Id: Ie5517d88429fbd4c58dbe5729de7c468d5d9a279 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com> Reviewed-by: Sérgio Martins <sergio.martins@kdab.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* QByteArray: add {const_,reverse_iterator}, {c,}r{begin,end}()Marc Mutz2015-07-071-0/+15
| | | | | | | | | | | | Had to mark {,c,const}{begin,end}() inline, since they are, and mingw complains about inconsistent dllimport attributes. [ChangeLog][QtCore][QByteArray] Added rbegin(), crbegin(), rend(), crend(), and reverse_iterator and const_reverse_iterator typedefs. Task-number: QTBUG-25919 Change-Id: Id5aefb52635f029305135afcd99db0b036a7af82 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Add shared implementation of a NSAutoreleasePool wrapper to qglobalTor Arne Vestbø2015-05-271-8/+4
| | | | | | | | | | | We have at least 5 different (but equal) implementations of a wrapper in Qt, and some code uses explicit NSAutoreleasePools. Having a shared implementation lets us clean up things a bit and makes it easier to reason about which pools are actually needed. Change-Id: I2fd8eefc3ae7308595ef9899b7820206268362a5 Reviewed-by: Tim Blechmann <tim@klingt.org> Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
* Fixed license headersJani Heikkinen2015-02-171-1/+1
| | | | | Change-Id: Ibebe1318d1c2de97601aa07269705c87737083ee Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
* Update copyright headersJani Heikkinen2015-02-112-29/+21
| | | | | | | | | | | | | | | | | | Qt copyrights are now in The Qt Company, so we could update the source code headers accordingly. In the same go we should also fix the links to point to qt.io. Outdated header.LGPL removed (use header.LGPL21 instead) Old header.LGPL3 renamed to header.LGPL3-COMM to match actual licensing combination. New header.LGPL-COMM taken in the use file which were using old header.LGPL3 (src/plugins/platforms/android/extract.cpp) Added new header.LGPL3 containing Commercial + LGPLv3 + GPLv2 license combination Change-Id: I6f49b819a8a20cc4f88b794a8f6726d975e8ffbe Reviewed-by: Matti Paaso <matti.paaso@theqtcompany.com>
* Merge remote-tracking branch 'origin/5.4' into devFrederik Gladhorn2015-01-212-0/+10
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/corelib/global/global.pri src/corelib/global/qcompilerdetection.h src/corelib/global/qglobal.h src/corelib/tools/qdatetime.cpp src/plugins/platforms/xcb/qxcbscreen.h src/plugins/platforms/xcb/qxcbwindow.h src/widgets/dialogs/qcolordialog.cpp src/widgets/dialogs/qcolordialog_p.h tools/configure/configureapp.cpp Change-Id: Ie9d6e9df13e570da0a90a67745a0d05f46c532af
| * Android: Fix QByteArray testEskil Abrahamsen Blomfeldt2015-01-062-0/+10
| | | | | | | | | | | | | | Include test data in qrc so it can be found on Android. Change-Id: Iaca8422120f1ef842aafeb0cc209cb9fdd70f05f Reviewed-by: BogDan Vatra <bogdan@kde.org>
* | Merge remote-tracking branch 'origin/5.4' into devOswald Buddenhagen2014-09-291-19/+11
|\| | | | | | | | | | | | | | | | | | | | | Conflicts: src/corelib/tools/qbytearray.cpp src/gui/image/qimage.cpp src/gui/image/qppmhandler.cpp src/gui/kernel/qguiapplication.cpp src/gui/painting/qpaintengine_raster.cpp Change-Id: I7c1a8e7ebdfd7f7ae767fdb932823498a7660765
| * Update license headers and add new license filesMatti Paaso2014-09-241-19/+11
| | | | | | | | | | | | | | | | | | - Renamed LICENSE.LGPL to LICENSE.LGPLv21 - Added LICENSE.LGPLv3 - Removed LICENSE.GPL Change-Id: Iec3406e3eb3f133be549092015cefe33d259a3f2 Reviewed-by: Iikka Eklund <iikka.eklund@digia.com>
* | Add rvalue-ref qualified overload of QByteArray::to{Upper,Lower}Thiago Macieira2014-08-191-0/+27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Those operations aren't very common with QByteArray but this is easy to optimize. Qt Qt Creator const & && const & && toLower 34 10 0 1 toUpper 3 1 0 0 Change-Id: I2097955f4c889ea5a21903c35ddbc0ff27bf62c5 Reviewed-by: Marc Mutz <marc.mutz@kdab.com> Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
* | Unify and optimize QByteArray::to{Upper,Lower}Thiago Macieira2014-08-191-0/+2
|/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | Do a check first if we need to transform before doing the transform. This means we won't detach when transforming data that is already correct. And instead of using QChar, use our own hand-rolled table. In a proper LTO build, the QChar calls would be resolved to a lookup of the Unicode data, but not many people do LTO builds, Therefore, this means a great speed-up is achieved by simply avoiding the function call. The extra gain in performance comes from the simpler translation table instead of the more complex full-Unicode data. Also as a consequence, this changes the handling of two characters in Latin 1: 'ß' should be uppercased to "SS" but we won't do it, and 'ÿ' can't be uppercased in Latin 1 ('Ÿ' is outside the range). Benchmarking is included. Comparing the Qt 5.4 algorithm to the new code is almost 20x faster. Other alternatives are included in the benchmark and are all faster than the current code, though slower than the new one. While all of them could compress the tables to be smaller or shared between uppercasing and lowercasing, they would also expand to more code (though probably less than the extra bytes required in the full translation table). In the trade-off, I decided to go with simplicity and most efficient code. Change-Id: I002d98318d236de0d27ffbea39d662cbed359985 Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* Fix QByteArray::to{Upper,Lower} when the array contains embedded nullsThiago Macieira2014-07-301-0/+27
| | | | | | | | | [ChangeLog][QtCore][QByteArray] Fixed a bug that would cause QByteArray to stop converting toUpper or toLower at the first embedded null character. Change-Id: Ia369037206617813d86a8f1489589243c82aa51b Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* Introduce std::string conversion to QByteArrayAllan Sandfeld Jensen2014-06-251-0/+19
| | | | | | | | | | | | | Add conversion methods similar to those in QString to QByteArray. This is often more useful than the QString version since std::string like QByteArray are byte arrays. [ChangeLog][QtCore][QByteArray] Added convenience methods to convert directly to and from std::string. Change-Id: I92c29d4bb1d9e06a667dd9cdd936970e2d272006 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
* Autotest: fix use of dangling pointerThiago Macieira2014-04-241-1/+1
| | | | | | | | | | | | The "data" pointer became technically dangling after line 1866 did copy = data; as copy was the last reference to the original data. That made the pointer address available to be reused by the system malloc(), which sometimes happened, causing the unit test to fail. Discussed-on: http://lists.qt-project.org/pipermail/development/2014-April/016588.html Change-Id: Ifa6a27bd53a6e60392b77a6609f2d47148695211 Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
* Fix capacity reservation for shared QByteArrayThiago Macieira2014-04-051-0/+15
| | | | | | | | | | | | We can squeeze, but not by discarding elements. Make sure the size of the object stays intact after changing the reserved capacity. I've also added unit tests for other containers, just to be sure. Task-number: QTBUG-37750 Change-Id: I5135b095943b7589423c51cebcb52af792468e61 Reviewed-by: Marc Mutz <marc.mutz@kdab.com> Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@digia.com>
* Add Objective-C specific type converters to QByteArraySamuel Gaist2014-03-083-0/+131
| | | | | | | | | | | | | | This patch adds the Objective-C NSData/CDataRef converters to QByteArray This will replace the current converters offered in QMacExtras [ChangeLog][QtCore][Objective-C] Added NSData/CDataRef converters for QByteArray Change-Id: I7a0f14bee4271798db345f3c5efd26ac671a3ea4 Reviewed-by: Jake Petroules <jake.petroules@petroules.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Base64: Implement the "base64url" encoding and the stripping of '='Thiago Macieira2013-09-141-0/+35
| | | | | | | | | The "base64url" encoding is defined in RFC 4648, which is the newest version of Base64. There are also a few situations where the ending '=' is not desired. Change-Id: I9bb9fa55817b57d125189e4e795d6fde97caea6d Reviewed-by: Richard J. Moore <rich@kde.org>
* tests: Fix some more old references and links to NokiaSergio Ahumada2013-02-011-4/+4
| | | | | | | Task-number: QTBUG-28156 Change-Id: Ifb768b167203c901c5e42ce58c9aaf3db2739320 Reviewed-by: Laszlo Papp <lpapp@kde.org> Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
* Update copyright year in Digia's license headersSergio Ahumada2013-01-181-1/+1
| | | | | Change-Id: Ic804938fc352291d011800d21e549c10acac66fb Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* Core: Remove declaration of built-in and automatic metatypes.Stephen Kelly2013-01-041-1/+0
| | | | | | | | These types are either built-in or 'automatically declared' and so don't need to be explicitly declared as metatypes. Change-Id: I54523eb854619917123d8816d3cd6c3a1f5b4c55 Reviewed-by: David Faure <david.faure@kdab.com>
* Remove metatype registration of built-in types.Stephen Kelly2013-01-031-1/+0
| | | | | | | | As they are built-in, they are effectively registered at compile-time already. Change-Id: I7ae6ba16088eab5d19213fa7b07c2a7760988a86 Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@digia.com>