summaryrefslogtreecommitdiffstats
path: root/src/corelib/tools
Commit message (Collapse)AuthorAgeFilesLines
* omit unassigned (and too recent) codepoints from the text Normalization processRitt Konstantin2011-09-012-6/+14
| | | | | | | | | | | | | | | http://www.unicode.org/reports/tr15/#Guaranteeing_Process_Stability: > handle any code points that were not defined in the earlier version > as if they were unassigned: such code points will not decompose or compose, > and their Canonical_Combining_Class value will be zero. since QChar::Unicode_Unassigned value is 0, it's less than any other QChar::UnicodeVersion value and must ba handled explicitly Change-Id: I6df025b4173d407660adae77ec5eeb98d15cb8ce Reviewed-on: http://codereview.qt.nokia.com/4084 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Rename the private helper function QList::free() to QList::dealloc()Bradley T. Hughes2011-09-011-7/+6
| | | | | | | | | | As the comment suggests, renaming this function avoids confusion with libc's free(). Change-Id: Ia077b92c947d81ef9d78de940a1cd8ed022edb3c Reviewed-on: http://codereview.qt.nokia.com/4063 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Remove declarations for QListData functions removed by 36c29abBradley T. Hughes2011-09-012-6/+2
| | | | | | | | | | | | | This commit removed the function implementations, but not the declarations. This removes QListData::append2(T) but moves the optimized QListData::append2(T) implementation to QListData::append(T) Change-Id: I39b6dea31420a7cefe079b94a91a96eb16000d2a Reviewed-on: http://codereview.qt.nokia.com/4062 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Add QLocale::toUpper/LowerLars Knoll2011-08-313-22/+49
| | | | | | | | | | | | | | | | | The toUpper/Lower() methods in QString should not be locale dependent, as this can lead to rather hard to find bugs in at least a turkish locale. Rather have explicit, locale dependend case conversions available in QLocale. Reviewed-by: Denis Dzyubenko (cherry picked from commit da0e1e101bb4c44c25b6523357fa81ad1b2d6539) Change-Id: I1cc3f341bef17ad573a736dc94c9c5d514ace54e Reviewed-on: http://codereview.qt.nokia.com/3259 Reviewed-by: Lars Knoll <lars.knoll@nokia.com> Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
* optimize parsing of templates like p{IsArabic}, etcRitt Konstantin2011-08-261-161/+160
| | | | | | | | | | | use qBinaryFind() with a case-sensitive string comparison instead of QHash. This also improves startup time and reduces runtime memory consumption. Change-Id: I5c5f7cae5e42acb3fa727acac19fe39c53310329 Reviewed-on: http://codereview.qt.nokia.com/3673 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* optimize parsing of templates like p{L}, p{Lu}, etcRitt Konstantin2011-08-261-98/+124
| | | | | | | | | | | replacing the if-else trees with the switch statement gives a 2x-3x parsing performance boost on parsing these expressions. Change-Id: Ia0e76ae4e1ab6930dbecf1d4a5232a4cc7198654 Reviewed-on: http://codereview.qt.nokia.com/3672 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* don't build code related to CClass if QT_NO_REGEXP_CCLASS is definedRitt Konstantin2011-08-261-0/+6
| | | | | | | Change-Id: If86835b1065eeb95e0774f1b42870dcd5225da58 Reviewed-on: http://codereview.qt.nokia.com/3671 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Remove all non-const operator==Harald Fernengel2011-08-091-2/+2
| | | | | | | | | | | We had to leave the non-const operator== for binary compatibility. Remove them all, just leave the const version in there. 100% source compatible. Change-Id: Ib7a70fb441fe51d5164d9cbf495cbeda0f48fafe Reviewed-on: http://codereview.qt.nokia.com/2773 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Robert Griebl <robert.griebl@nokia.com>
* Fix QString/QByteArray literals for MSVC2010 (compilation of tests).Friedemann Kleint2011-08-022-9/+16
| | | | | | | | | | - Specify return type of QByteArrayLiteral/QStringLiteral lambdas. - Define QT_UNICODE_LITERAL instead of QT_UNICODE_MARKER. Change-Id: I8a53506887d2736b093798220b088f645f05e415 Reviewed-on: http://codereview.qt.nokia.com/2514 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: João Abecasis <joao.abecasis@nokia.com>
* Fix compilation with namespaced buildsBradley T. Hughes2011-07-291-0/+5
| | | | | | | | | | Add QT_BEGIN_NAMESPACE and QT_END_NAMESPACE to src/corelib/tools/qfreelist.cpp Change-Id: Ie01e74a3c2d9cd4de1f52a546d13398e1409c86b Reviewed-on: http://codereview.qt.nokia.com/2390 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Olivier Goffart <olivier.goffart@nokia.com> Reviewed-by: João Abecasis <joao.abecasis@nokia.com>
* Added meta type info for Q[Explicitly]SharedDataPointerDenis Dzyubenko2011-07-281-0/+3
| | | | | | | Change-Id: I1269630ae5154f7318e1c7ae9fa2014a15234bf4 Reviewed-on: http://codereview.qt.nokia.com/2110 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Olivier Goffart <olivier.goffart@nokia.com>
* Get rid of compiler warnings with MSVCOlivier Goffart2011-07-283-21/+22
| | | | | | | Change-Id: Ibd027c502a5b8bcbfc6dae71c4f244f1080d4064 Reviewed-on: http://codereview.qt.nokia.com/2303 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
* Add QFreeList as an internal classBradley T. Hughes2011-07-263-0/+358
| | | | | | | | | | | | | | | | | | | | | This is a generic implementation of the lock-free free list found in qabstracteventdispatcher.cpp. Use next() to get the next free entry in the list, and release(id) when done with the id. This version is templated and allows having a payload which can be accessed using the id returned by next(). The payload is allocated and deallocated automatically by the free list, but *NOT* when calling next()/release(). Initialization should be done by code needing it after next() returns. Likewise, cleanup should happen before calling release(). It is possible to have use 'void' as the payload type, in which case the free list only contains indexes to the next free entry. Autotest included. Change-Id: Ifd12a961d47f3d76593c45061f72e55c9b80a43b Reviewed-on: http://codereview.qt.nokia.com/2160 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Olivier Goffart <olivier.goffart@nokia.com>
* Changed QLibrary::resolve() to return a function pointer.Kim Motoyoshi Kalland2011-07-251-1/+1
| | | | | | | | | | | According to the C++ standard, there is no guarantee that you can cast between function pointers and void pointers without data loss (section 5.2.10-6). Change-Id: I27f4d835e4c8ca8ecca0d76cfea9ce34491956bd Reviewed-on: http://codereview.qt.nokia.com/1995 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: João Abecasis <joao.abecasis@nokia.com>
* QAbstractConcatenable::convertFromAscii: make len the actual lengthOlivier Goffart2011-07-222-10/+7
| | | | | | | | | | | | | | | Before, it was the length + 1, to include the ending \0 (for historical reasons) Having it the actual length is more intuitive and less error prone Also added QT_ASCII_CAST_WARN to QConcatenable<QByteArray>::appendTo to show the warnig that convertion from ascii to qstring occurs. Change-Id: Ie7c8552b6b4e7ccb393cb09f5f0ca9b00336c714 Reviewed-by: thiago Reviewed-on: http://codereview.qt.nokia.com/1988 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Olivier Goffart <olivier.goffart@nokia.com>
* remove Qt3 leftoversRitt Konstantin2011-07-221-11/+2
| | | | | | | | | | Merge-request: 22 Reviewed-by: Olivier Goffart <olivier.goffart@nokia.com> Change-Id: I5d25fb05894d9baa645f97946e1f9aaa1622c876 Reviewed-on: http://codereview.qt.nokia.com/1925 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Olivier Goffart <olivier.goffart@nokia.com>
* Add unit tests to QStringLiteral and QByteArrayLiteral with operator %Thiago Macieira2011-07-211-0/+21
| | | | | | | | | | This requires a fix for QByteArrayLiteral to work too. Change-Id: I3c2a50ad431d5b0c014a341e675fa54e7b206e70 Merge-request: 27 Reviewed-by: Olivier Goffart <olivier.goffart@nokia.com> Reviewed-on: http://codereview.qt.nokia.com/1967 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
* Make the N parameter to the QXXXLiterals be the actual string lengthThiago Macieira2011-07-212-16/+16
| | | | | | | | | | | | Before, it was the length + 1, to include the ending NUL or U+0000. This avoids mistakes of -1 in QStringBuilder and will allow us simpler code in the User-Defined Literal (future improvement) Change-Id: I75c47d6c44579124888f925e240817229347dc70 Merge-request: 31 Reviewed-by: Olivier Goffart <olivier.goffart@nokia.com> Reviewed-on: http://codereview.qt.nokia.com/1966 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
* minor improvements to QChar documentationRitt Konstantin2011-07-211-68/+42
| | | | | | | | | | Merge-request: 22 Reviewed-by: Olivier Goffart <olivier.goffart@nokia.com> Change-Id: Ib70922f98385888c084ccd3224a9bb12ca766ccf Reviewed-on: http://codereview.qt.nokia.com/1926 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Olivier Goffart <olivier.goffart@nokia.com>
* Fix more use of C style cast.Olivier Goffart2011-07-211-3/+3
| | | | | | | | | | | Commit 77ed8787ac9ef0f74c2ab6699af3fec434e433e5 was not enough Fix the test tst_Moc::oldStyleCasts() Change-Id: Ia2f98f4e02ba512c3f7fd7cd09b692a1aabd8de0 Reviewed-on: http://codereview.qt.nokia.com/1927 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
* Doc: Removed documentation for deleted code.David Boddie2011-07-2110-896/+0
| | | | | | | Change-Id: Icdbc05decac3dfe3fc18ce073c494e1fce4ea347 Reviewed-on: http://codereview.qt.nokia.com/1824 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: David Boddie
* Fix use of C style cast.Olivier Goffart2011-07-191-1/+1
| | | | | | | | | | | | | Fix the test tst_Moc::oldStyleCasts() (The test make sure moc do not generate old C cast, by compiling the generated code and testing for gcc warning. But if it is present in the public header, the warning will be shown) Change-Id: I2fd3d01e7d78639d97bea021c200afbe2caae85f Reviewed-on: http://codereview.qt.nokia.com/1772 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
* "Fix" the crash at startup on MSVCOlivier Goffart2011-07-151-2/+2
| | | | | | | | | | | | | | | | | | | | | The problem is that for some reasons, QByteArray::shared_null (and probably shared_empty, and the ones for QString) are not in the .rodata anymore, and they are initialized by code. programs like QMake, which has others global objects (like global QFiles) that uses QByteArray crashes, because they reference and dereference shared_null (and try to destroy shared_null) That happens before shared_null's refcount is initialized to -1 The solution here is not to ref() the objects that have a refcount of 0 (that is what the refcount is before it is initialized to -1) The real fix to this problem would be to understand why it is not in the proper section, and make sure it is. Change-Id: I5b7e966ed4c460b90dba70855f4dc50685dff97f Reviewed-on: http://codereview.qt.nokia.com/1712 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
* fixup for d17c76feee9eece4f7d9d1c5cec254842bb0a639Ritt Konstantin2011-07-151-50/+151
| | | | | | | | | | | | | | removing the NoCategory enum value caused all category flags to change. not an issue for qchar where they were used properly, but an issue for qregexp where the hardcoded values were used instead. the `all_cats` could be set to `FLAG(QChar::Symbol_Other + 1) - 1` which is shorter, but I don't want hardcode the values in order to avoid similar issues in he future Change-Id: Ie3ae2fca1b01d5911b834f439a0a6216766b8a20 Merge-request: 21 Reviewed-by: Olivier Goffart <olivier.goffart@nokia.com> Reviewed-on: http://codereview.qt.nokia.com/1696 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
* Revert "make QChar::Unicode_Unassigned a constantly big value"Olivier Goffart2011-07-151-2/+2
| | | | | | | | | | | | This reverts commit ebfd24a20b1acdced5fe032eedb2737efdc6eb92. Breaks QChar and QString autotests Change-Id: If1e915520ea491262c5f7753368be98c02ddac5e Reviewed-by: Ritt Konstantin Reviewed-on: http://codereview.qt.nokia.com/1672 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Olivier Goffart <olivier.goffart@nokia.com>
* Regenerate unicode tablesOlivier Goffart2011-07-151-880/+880
| | | | | | | | | Required after d17c76feee9eece4f7d9d1c5cec254842bb0a639 Change-Id: I6820b5cbb78636aa5348bdddf8824ea5c78ba934 Reviewed-on: http://codereview.qt.nokia.com/1673 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Olivier Goffart <olivier.goffart@nokia.com>
* make QChar::Unicode_Unassigned a constantly big valueRitt Konstantin2011-07-131-2/+2
| | | | | | | | this makes the version based checks a bit simpler (and thus faster) Change-Id: I975c6d043d238a5c16a4b13f8379e87fbade23cc Reviewed-on: http://codereview.qt.nokia.com/1586 Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* drop a dead QChar::Punctuation_Dask enum valueRitt Konstantin2011-07-132-5/+1
| | | | | | Change-Id: I22c67ff7c08ab514a646bad86eb8cd0f41099e9c Reviewed-on: http://codereview.qt.nokia.com/1585 Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* drop an obsolete QChar::NoCategory enum valueRitt Konstantin2011-07-132-5/+1
| | | | | | | | | | | | there is no such category in the Unicode specs. the QChar::NoCategory was a subject of bugs since it was introduced. int 4.6 it's meaning was limited to mention ucs4 > UNICODE_LAST_CODEPOINT only (which is useless anyways) in order to preserve the old (wrong) behavior. fix it now for qtbase Change-Id: I630534824e071090b39772881e747c1fdb758719 Reviewed-on: http://codereview.qt.nokia.com/1584 Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Fix compilation on MSVCLars Knoll2011-07-132-17/+51
| | | | | | | | | | | MSVC apparently doesn't like the way the QString::Data pointers got initialized. Also fixed a few warnings about signed/unsigned conversions. Change-Id: I1267979af7601129e5483f8785d4982a1f2f8182 Reviewed-on: http://codereview.qt.nokia.com/1558 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
* Refactor QByteArray to allow for const dataLars Knoll2011-07-122-186/+257
| | | | | | | | | | | | | Similar refactoring as done for QString. Make shared_null read-only, and add support for compile time generated QByteArrayData. Add support for properly reserving capacity. Change-Id: Ie4c41d4caac7b3b4bb1aef40c1c860a30b82edb8 Reviewed-on: http://codereview.qt.nokia.com/1484 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Olivier Goffart <olivier.goffart@nokia.com>
* Cleanup reference counting in QDateTimePrivate class.Jedrzej Nowacki2011-07-121-3/+2
| | | | | | | | | | It is better to use QSharedData which is a common interface for ref counting. Change-Id: I990476d6763901bf383f241bce16fe26665b021c Reviewed-on: http://codereview.qt.nokia.com/1439 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Olivier Goffart <olivier.goffart@nokia.com>
* remove unneeded cast operator on QConstStringDataLars Knoll2011-07-121-3/+0
| | | | | | | Change-Id: Ib5f090cd6c716e1d936894be206b78629e70137b Reviewed-on: http://codereview.qt.nokia.com/1487 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Olivier Goffart <olivier.goffart@nokia.com>
* Remove #ifdef for platforms where QChar was packed -- there aren't anyThiago Macieira2011-07-111-4/+0
| | | | | | | | | | | | On ARM OABI, sizeof(QChar) was 4, so we used to pack it so QChar[] was isomorphic to ushort[]. We don't support the OABI anymore and the EABI does the right thing. Change-Id: I181dd2f169f6868450302e269ef9ad5d643f306f Merge-request: 13 Reviewed-by: Olivier Goffart <olivier.goffart@nokia.com> Reviewed-on: http://codereview.qt.nokia.com/1386 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
* Remove Qt 4.3 binary compatibility for MSVCThiago Macieira2011-07-115-49/+0
| | | | | | | | | | | | | | | When we removed the useless "const" in the return type, we broke compatibility with a few compilers that include the return type in the mangling. We don't need that anymore in Qt 5. This change should have had a ### Qt5 mark everywhere, not just in a comment in qstring.cpp. Change-Id: I8839f8dc540b34e57a3efdb160a1c015f7328422 Merge-request: 13 Reviewed-by: Olivier Goffart <olivier.goffart@nokia.com> Reviewed-on: http://codereview.qt.nokia.com/1385 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
* Use lambdas for generating static data for QStringLiteralThiago Macieira2011-07-111-26/+33
| | | | | | | | | | | This means it will work on C++0x compilers that support lambdas (all of them once they've completed supporting the functionality). Olivier had the idea and the initial code. Change-Id: I11ef7da4058ed18f4ea99ada070891a68ed54f55 Reviewed-on: http://codereview.qt.nokia.com/1380 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Olivier Goffart <olivier.goffart@nokia.com>
* Remove the qs() macro.Olivier Goffart2011-07-081-4/+0
| | | | | | | | | | | There is tootoo many risks of conflicts with existing code. QStringLiteral is not that hard to type. And if users want to use qs they can still define it in their own headers. Change-Id: I7da4772d902033fa163f5177c012b5d0e87332d7 Reviewed-on: http://codereview.qt.nokia.com/1357 Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Use memmove in QListData::append(int) as regions overlap.Thiago Macieira2011-07-081-1/+1
| | | | | | | | | It's undefined behaviour to memcpy regions with overlapping area. You have to use memmove. Change-Id: I912c819bf7ab26ba1e60028ee9d7c833dfc5138a Reviewed-on: http://codereview.qt.nokia.com/1355 Reviewed-by: Olivier Goffart <olivier.goffart@nokia.com>
* Add support for QStringLiterals in QStringBuilderThiago Macieira2011-07-081-0/+17
| | | | | | | | | | | Otherwise we get errors for failing to have operator+ properly when writing: QStringLiteral("foo") + s Change-Id: I03844c95e9fdfa886eadfa2b5fe104ff048fd618 Reviewed-on: http://codereview.qt.nokia.com/1351 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Make the new QStringLiteral produce a non-temporaryThiago Macieira2011-07-081-10/+33
| | | | | | | | | | | | | | | | | This is currently GCC-only code (the __extension ({ }) stuff), but it was the only way I found to create a static variable and return it. I had to add the QConstStringDataPtr container because I had to return a pointer to the data -- it's impossible to return a reference through this extension. I could have returned a naked pointer directly too. This isn't complete. GCC 4.6 is placing the string in the .data section, not .rodata as we wanted. Investigating further. Change-Id: I170030dca3eddbd69f6c879e952f652f7fe5d958 Reviewed-on: http://codereview.qt.nokia.com/1350 Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Bugfix the QConstString implementation.Thiago Macieira2011-07-081-2/+2
| | | | | | | Change-Id: Ic9ea9d91c1a976962a3881ecdf7ad178de768b08 Reviewed-on: http://codereview.qt.nokia.com/1349 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Unify QLatin1String and QLatin1LiteralLars Knoll2011-07-074-123/+57
| | | | | | | | | | | | | Unify the two classes and get rid of one TODO item for Qt 5. Using strlen in the constructor of QLatin1String works, as the compiler can do the calculation at compile time. Change-Id: I59d98c71a34b86d4211fa0d8cfd40b7d612c5a78 Reviewed-on: http://codereview.qt.nokia.com/1219 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Olivier Goffart <olivier.goffart@nokia.com>
* Support for compile time generated QStringsLars Knoll2011-07-072-282/+287
| | | | | | | | | | | | | | | | | | | | | | | | | | use with QString string(QStringLiteral("foo")) or QString string(qs("foo")). qs(...) can in almost all places replace QLatin1String. the Macro qs requires c++0x support or a compiler where sizeof(wchar_t) == 2. In case these conditions are not met, qs simply falls back to QLatin1String. The commit also cleans up the QStringData structure significantly, now using only 16 bytes for the header on 32 bit systems. The bitflags to store unicode directionality of the string and whether the string would require complex text processing to render are removed. They don't really belong here and the result can be calculated very fast in any case. Added an internal QRefCount class the encapsulates the reference counting semantics required where a negative refcount is never changed. This is required to be able to put the string data into a constant POD object. Change-Id: I5b1395213deca48b2d582a036a0e8a8358d26d14 Reviewed-on: http://codereview.qt.nokia.com/1218 Reviewed-by: Olivier Goffart <olivier.goffart@nokia.com> Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Add an internal QRefCount class to QtCoreLars Knoll2011-07-073-0/+145
| | | | | | | | | | | The class will be used by QString and possibly other container classes to allow for the Data objects to be created at compile time in read-only memory. Change-Id: I9c7538bc97df637cc920e6e5ef23d67a93abac0d Reviewed-on: http://codereview.qt.nokia.com/1216 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Olivier Goffart <olivier.goffart@nokia.com>
* Fix compilation with c++0x modeLars Knoll2011-07-061-1/+1
| | | | | | | Change-Id: Ie4f157f25c31e46d4cc7cb628b8605b99561a4e8 Reviewed-on: http://codereview.qt.nokia.com/1220 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Olivier Goffart <olivier.goffart@nokia.com>
* Fix QScopedPointerarray default constructorOlivier Goffart2011-07-051-1/+3
| | | | | | | | | | | | | | Since the compiler cannod find the template argument if there is no argument passed to the constructor, this effectively means there is no default constructor. Add a default constructor Task-number: QTBUG-20256 Change-Id: I310d5e1f3f94a8fe69fd3a5c46f2f51bca60facd Reviewed-on: http://codereview.qt.nokia.com/1165 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Denis Dzyubenko <denis.dzyubenko@nokia.com>
* remove QT3_SUPPORT from corelib/toolsLars Knoll2011-06-2911-346/+0
| | | | | | | Change-Id: Ie224cf992be675c7d405d4be05e4acd4157e590e Reviewed-on: http://codereview.qt.nokia.com/863 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Liang Qi <liang.qi@nokia.com>
* Remove Qt3 support functionality from parts of QtCoreLars Knoll2011-06-292-211/+14
| | | | | | | Change-Id: I90f391e9bfc412087bd0401e28d2497571f81aa1 Reviewed-on: http://codereview.qt.nokia.com/825 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Liang Qi <liang.qi@nokia.com>
* QStringBuilder: do not crash with null char*Olivier Goffart2011-06-272-0/+4
| | | | | | | | | This is supported by the others operator+ Change-Id: I9a1d1a0afb63acf32935948111d43ca6da370363 Reviewed-on: http://codereview.qt.nokia.com/764 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: hjk <qthjk@ovi.com>
* Make QPoint have the same layout on all platformsGunnar Sletta2011-06-201-6/+0
| | | | | | | Change-Id: I8330295761a4440afd81c121039237fb651d9a9c Reviewed-on: http://codereview.qt.nokia.com/487 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Lars Knoll <lars.knoll@nokia.com>