aboutsummaryrefslogtreecommitdiffstats
path: root/sources/shiboken2
Commit message (Collapse)AuthorAgeFilesLines
* Bump version numbersSimo Fält2019-11-111-1/+1
| | | | | Change-Id: I320da3f8bb09774db8c4e88c784a0d270eb1c932 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* Fix Python 3 deprecation warning about Buffer APIFriedemann Kleint2019-10-251-0/+4
| | | | | | | | | Use new buffer protocol, fixing: sources/shiboken2/libshiboken/shibokenbuffer.cpp: In function ‘bool Shiboken::Buffer::checkType(PyObject*)’: sources/shiboken2/libshiboken/shibokenbuffer.cpp:46:42: warning: ‘int PyObject_CheckReadBuffer(PyObject*)’ is deprecated [-Wdeprecated-declarations] Change-Id: I3e3a403306d86c940bf1bd71fc672db6e0a2ea60 Reviewed-by: Christian Tismer <tismer@stackless.com>
* abstractmetabuilder_p.h: Fix compilation with some versions of g++Friedemann Kleint2019-10-251-1/+1
| | | | | | | | | | Fix the return type, which caused complaints by some versions of g++: sources/shiboken2/ApiExtractor/abstractmetabuilder_p.h: In member function 'ScopeModelItem AbstractMetaBuilderPrivate::popScope()': sources/shiboken2/ApiExtractor/abstractmetabuilder_p.h:61:57: error: could not convert 'QList<T>::takeLast() [with T = QSharedPointer<_NamespaceModelItem>]()' from 'QSharedPointer<_NamespaceModelItem>' to 'QSharedPointer<_ScopeModelItem>' Change-Id: I94abdfb9d76d3f0078e198b4230129150d2f43ea Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
* Shiboken: QtDoc: Fix how brief and class tags are handledVenugopal Shivashankar2019-10-251-5/+1
| | | | | | | | | | | - The brief attribute of a page tag should be ignored to avoid briefs appearing twice. - The class ref pages should use the .. currentmodule:: rst directive instead of the .. module::. Change-Id: Iac205d60f79db49eb8c69a2593f09fb206a5b1a3 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* shiboken: Fix pyi generation for external modulesAndreas Beckermann2019-10-251-5/+0
| | | | | | | | | | | | | | | enum_sig.py is used to generate .pyi files (in sources/pyside2/PySide2/support/generate_pyi.py) from the bindings. The file can also be useful by external modules that were generated by shiboken, however the check for the modulename being PySide2 or shiboken2 prevents this. Remove this check, as discussed on IRC. This seems to be working internally as well and re-adds support for usages by external modules. Change-Id: I81af943c43f8f84aa0b0d89260cd99215acdb10d Reviewed-by: Christian Tismer <tismer@stackless.com>
* Fix hasVirtualDestructor() for implicit destructorsAndreas Beckermann2019-10-253-1/+39
| | | | | | | | | | | | | | | | | If a derived class does not declare an explicit destructor, AbstractMetaClass::hasVirtualDestructor() is set to false. However this is incorrect for classes that have a base class that in turn provide a virtual destructor. Consequently shiboken generates incorrect code in cases where it depends on that value (e.g. for methods that override ownership of the returned object - instead of releasing ownership, shiboken invalidates it). This patch considers the baseClass()->hasVirtualDestructor() after traversing all functions (which checks for explicit destructors). Change-Id: Ifc4a472290d835dd6ef7d702b912643c9a2b42da Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* Add support for __repr__ in QObject derived classesAndreas Beckermann2019-10-255-12/+28
| | | | | | | | | | | | | | | | | | | | | | Currently shiboken generates classes without __repr__ for QObject derived classes. However for all non-QObject classes that have an operator<<() for QDebug, it *does* add a valid repr implementation. Extend this behavior to QObject classes as well. In order for this to become more useful, also check for the indirection of operator<<(): If operator<<(QDebug, Foo*) is available, use the current non-value-type behavior, (i.e. provide cppSelf to operator<<()), but if operator<<(QDebug, const Foo&) is available instead, use the same behavior as for value-types, i.e. provide *cppSelf. This greatly increases the number of classes where operator<<() provides useful results. Also make sure to check for operator<<() in namespaces (recursively), not just at global scope. Change-Id: Ief9158455a25e332f07169f09692cafb8097078b Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* Shiboken: QtDoc generator: Handle 'group' tag as a 'page' tagVenugopal Shivashankar2019-10-151-4/+6
| | | | | | | | Also, add a title for the resulting rst either using the fullTitle or the title attribute. Change-Id: If8be6a9a6db2cfc86bc4b646159ccc6f2210e243 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* Shiboken: Provide a context for the additional docsVenugopal Shivashankar2019-10-071-1/+2
| | | | | | | | | Without the context, the images referred in the additional docs are not copied to the target directory. As as result, we have missing images in the HTML. Change-Id: I76bf4dafaa9ff82ef11755a64da7466596969460 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* shiboken: Fix handling of modified default expressionsFriedemann Kleint2019-10-046-5/+48
| | | | | | | | | | - Do not try to resolve modified default expressions (add enumeration scopes or similar) - Fix the signature parser to handle arbitrary expressions Fixes: PYSIDE-1095 Change-Id: I059c3a1f066687d7c2f0dad9ea7f0d93e292b1b5 Reviewed-by: Christian Tismer <tismer@stackless.com>
* Fix bad shutdown effect on QApplication.instance()Christian Tismer2019-09-301-2/+7
| | | | | | | | | | | | | | | | | | | | | | | When app = QtWidgets.QApplication.instance() is used before a QApplication has been created, the qApp code sees no qApp instance in C++ and assumes a shutdown. This patch keeps track of QApplication being created and behaves correctly on that aspect. It is still unsolved that QtCore.QObject.staticMetaObject gets deleted on a qApp shutdown, which is too much. I think this can be handled in another patch if at all, since the shutdown / recreate feature is undocumented and of little use. Change-Id: I140b6dba45f7cd337580373dbf72bc6d0a625fea Fixes: PYSIDE-1093 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
* Remove trailing whitespace from __repr__Andreas Beckermann2019-09-271-0/+1
| | | | | | | | | | | | | | | | | QDebug normally prints a trailing ' ', however the repr implementation does not expect so. Remove the trailing space, if it is there. This makes sure that e.g. PySide2.QtCore.QRegularExpression() is printed as <PySide2.QtCore.QRegularExpression("", QRegularExpression::PatternOptions("NoPatternOption")) at 0x1067a5d20> instead of <PySide2.QtCore.QRegularExpression("", QRegularExpression::PatternOptions("NoPatternOption")) at 0x1067a5d20> (note the double space before 'at') Change-Id: I6c088069a6a8ca42933a442cce7b576327a9d151 Reviewed-by: Christian Tismer <tismer@stackless.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* Shiboken: Add check for 'external' link typeVenugopal Shivashankar2019-09-251-0/+2
| | | | | | | | | | | Apparently, qdoc generates <link...> entries with 'external' type, which is ignored by Shiboken. This leads to treating such links as reference links, leading to broken links in the HTML output. Change-Id: I426f91661ba1cc0b0f17b2e30fbddcf9e1fee530 Reviewed-by: Topi Reiniö <topi.reinio@qt.io> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* Merge remote-tracking branch 'origin/5.12' into 5.13Friedemann Kleint2019-09-111-0/+1
|\ | | | | | | Change-Id: I7f3e2a11fe744b5c868698e63cf10882c168c53f
| * Fix heaptype conflict with QtCore.QObject.__new__in Python 2.7Christian Tismer2019-09-061-40/+54
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The patching of the type generation needs to become universal. Additional to the patch for SbkObjectType_TypeF, we now patch * SbkObjectTypeTpNew * introduceWrapperType which makes the modifications for the heaptype flag complete. Actually, the modification of tp_new_wrapper has to be more sophisticated in this general case: We follow the __mro__ and patch exactly those functions which have the old wrapper and add the new wrapper. Change-Id: I51d4d77c99bd18eed2e31d2ab21143c0f4e2ea6c Fixes: PYSIDE-1051 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io> (cherry picked from commit cd6172063756a59e02f1a7857bc60a1737214ad1)
| * Bump version for 5.12.5Simo Fält2019-08-271-1/+1
| | | | | | | | | | Change-Id: I741a7880bf87cca4a6482cc0e07e6f878e2e02b3 Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
* | Bump version to 5.13.2Simo Fält2019-09-061-1/+1
| | | | | | | | | | Change-Id: I4e65ab4e24d563372e548f426b830a9490b8e99f Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* | Fix heaptype conflict with QtCore.QObject.__new__in Python 2.7Christian Tismer2019-09-031-40/+54
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The patching of the type generation needs to become universal. Additional to the patch for SbkObjectType_TypeF, we now patch * SbkObjectTypeTpNew * introduceWrapperType which makes the modifications for the heaptype flag complete. Actually, the modification of tp_new_wrapper has to be more sophisticated in this general case: We follow the __mro__ and patch exactly those functions which have the old wrapper and add the new wrapper. Change-Id: I51d4d77c99bd18eed2e31d2ab21143c0f4e2ea6c Fixes: PYSIDE-1051 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
* | Doc: Improve the documentation styleTopi Reinio2019-09-021-20/+76
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Restyle the admonition (warning/note/seealso) paragraphs, use the same font for all link types, and separate entries with ', '. - Drop the rounded corners on multiple section titles. - Use a monospace font for enumeration tables (value column). - Restyle the <blockquote> element that is used for overload/parameter docs to separate them from the documentation 'body'. - Replace list-style-type:'' with list-style:none as the former does not work on all browsers. Change-Id: I0c37bd05448d7ce38a47af7449ca0bc9efff68b4 Reviewed-by: Venugopal Shivashankar <Venugopal.Shivashankar@qt.io>
* | signature: Support typing.Optional[T] and refine a bitChristian Tismer2019-08-297-57/+109
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The signature was missing "typing.Optional[T]" which has to be wrapped around any argument with a default value of "None". This is the only case where the repr of a type looks different than it was written, because it renders as "typing.Union[T, NoneType]". Solving that by redefining a few typing structures was way too hard and too error prone. It was finally solved by a regex replacemet that is run as a post process in generate_pyi.py . The enumerations are now even more complete, since toplevel enums are also included. This had the effect that enums with Python keywords were revealed, and so the function "createEnumItem" had to be modified. The order of creation was also changed to avoid name clashes. The overall structure was improved, and instead of parsing the generated signatures to find out if something is a class method, this is now very cleanly implemented as an inquiry to get_signature(). I tried to make sense of the flags structure that comes with many enums. PyQt5 has a standard set of "__...__" methods without useful signature information. I could mimick that as well, but that would create a whole lot of pointless extra information. We should decide later if it makes sense to include that. Right now the flags structures show the class name, only. This patch will be merged with the 5.14 branch. The additions of this patch could fortunately be placed into areas which do almost not overlap with the 5.14 signature additions. Change-Id: Ie513e15917b04d746ab597fb7a9eb1fd766f7c73 Fixes: PYSIDE-1079 Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
* | CMake modularization: macros creationCristián Maureira-Fredes2019-08-285-261/+316
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | First step of this process that only considers the idea of encapsulate the diffrent CMake processes we currently have in all our main CMakeLists.txt files. This patch simply takes some sections of the existing cmake files and move them to a macro file. Additionally, a couple of macros were written twice in shiboken and pyside, so now they are only once. Task-number: PYSIDE-1033 Change-Id: I2c63d8a2eba3d8951097ec9c9042c782fde5dd62 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Christian Tismer <tismer@stackless.com>
* | Fix a typing bug in Python 2.7 and updateChristian Tismer2019-08-222-94/+431
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The typing module has problems if it exists twice. This gave trouble with matplotlib, when typing was imported and then called PySide indirectly. The only reliable cure appears to be to use the typing module if it is already in sys.modules . The typing27 modue was updated to the latest version of https://github.com/python/typing (original file with additional license headers). Fixes: PYSIDE-1073 Change-Id: Iebfdfe7fd51080a9334db332719928c001501381 Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
* | Add QtCore.Slot.__signature__ and much more manuallyChristian Tismer2019-08-214-17/+61
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The signature of QtCore.Slot and other classes could not automatically be generated because the function is not generated by cppgenerator.cpp . We add it manually in the C++ code into the generation process. The case of QtCore.Slot had diverse follow-up issues to be solved: - Classes which did not inherit from Shiboken were not generated. This is a long-standing omission and creates very many new simple types. - The arity of Slot has default arguments after the varargs parameter "*types". This needed an extended Python parser analysis that fixes the arguments given to the inspect module, accordingly. - The signature generation was completely new implemented and relies no longer on the restricted syntax of a Python (2) function but generates signatures directly as Parameter instances. Implemented classes with hand-made signatures: QtCore.ClassInfo QtCore.MetaFunction, QtCore.MetaSignal QtCore.Property QtCore.Signal QtCore.SignalInstance QtCore.Slot QtQml.ListProperty QtQml.VolatileBool As a side effect, many more subtypes were published. Enums are done, which concludes this work. Fixes: PYSIDE-945 Fixes: PYSIDE-1052 Change-Id: Ic09f02ece3a90325519e42e4e39719beb0c27ae9 Reviewed-by: Christian Tismer <tismer@stackless.com>
* | Update docs styleCristián Maureira-Fredes2019-08-201-12/+79
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Some upgrades to improve the readability: * Reduce margins, * Remove round-corners from boxes, * Remove parameters and return type boxes and use bold instead, * Always show the Table of Contents. Task-number: PYSIDE-1067 Change-Id: Ibaa484172103eff17426ae03ee6f95c78fe51143 Reviewed-by: Venugopal Shivashankar <Venugopal.Shivashankar@qt.io> Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
* | Bump version to 5.13.1Simo Fält2019-08-151-1/+1
| | | | | | | | | | Change-Id: I88699b3231707d77014b0ee2fb1e8a710484f66e Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* | Make signatures even more writableChristian Tismer2019-08-141-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When implementing QtCore.Slot.__signature__, the following extension to writable signatures became useful: Signatures were corrected to be writable if they were not set by the signature module at all. But we should also allow assignment when the signature was set to None. This feature is only used for exploration; the correct way to implement a new signature is to integrate it into the normal generation process, as being done for QtCore.Slot.__signature__. Change-Id: I010e505a376993f27c46bd1c14e327e44d375abd Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* | Merge remote-tracking branch 'origin/5.12' into 5.13Friedemann Kleint2019-08-146-11/+43
|\| | | | | | | Change-Id: Ibe27e8ef7edc487640bc9cf1fe113d2d27e1e291
| * Fix crash when accessing a invalid property in the smart pointerRenato Araujo Oliveira Filho2019-08-073-1/+21
| | | | | | | | | | | | | | | | Sbk_*_getattro receives an utf8 string and we need to convert it to ascii string before use it on PyErr_Format. Change-Id: Ie3cf5286c9eb6b01f86347b00d523837ca41de32 Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
| * shiboken: Allow for "auto" as target of type for CONVERTTOCPP in injected codeFriedemann Kleint2019-07-292-1/+3
| | | | | | | | | | | | Task-number: PYSIDE-1037 Change-Id: Idfc70fe571e4058d0c82db1bd0afea54436fe27c Reviewed-by: Christian Tismer <tismer@stackless.com>
| * shiboken: fix a signature bug in __doc__ handling of global functionsChristian Tismer2019-07-231-9/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The signature module was extended to allow automatic creation of __doc__ attributes by taking str of the signature. This function has to figure out when it should not touch an object that does not come from PySide. The check asked the type that was returned by GetClassOfFunc, but in case of a global function, the module of the function is returned. In order to prevent such mistakes, the function has been renamed to GetClassOrModOf. Change-Id: I055f1f0483674553f9300d642aa516cec607e66c Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io> Reviewed-by: Keith Kyzivat <keith.kyzivat@qt.io>
* | Fix RuntimeError: dictionary changed size during iterationJulien Schueller2019-07-191-1/+1
| | | | | | | | | | | | | | | | Seems the dictionary of modules needs to be copied before iterating Fixes https://github.com/spyder-ide/qtpy/issues/195 Change-Id: I8517e031c4a250856d3318b364b1cd5dab3f8f80 Reviewed-by: Christian Tismer <tismer@stackless.com>
* | Merge remote-tracking branch 'origin/5.12' into 5.13Alex Blasche2019-07-1814-283/+616
|\| | | | | | | Change-Id: Ic2c43ef80769e3063dac771518c803861510f72e
| * Cleanup signature module before substantial changeChristian Tismer2019-07-177-276/+557
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There were some refinements applied while developing "Support Pointer Primitive Types by Arrays or Result Tuples". This patch moves these changes out which are not essential for that patch. They include - sort all mapping groups by name - replace huge regex by a pattern generator - replace dictionary string entries by SimpleNameSpace - improve PEP 563 handling - simplify "zero(sometype)" substantially - better handling of "QGenericMatrix" (preview) A test for the generated pattern against a reference parser was added. Task-number: PYSIDE-795 Task-number: PYSIDE-951 Change-Id: I5a6b236850c63a7db77b7f7b88881486fd1e61be Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
| * Add optional support for types in QSettings::valueCristián Maureira-Fredes2019-07-171-3/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This add an optional named parameter to the function value() to automatically cast the type that is being returned by the function. An example of this situation could be an ini file that contains the value of a one-element list: settings.setValue('var', ['a']) The the ini file will be: [General] var=a # we cannot know that this is a list! Once we read it, we could specify if we want the default behavior, a str, or to cast the output to a list. settings.value('var') # Will get "a" settings.value('var', type=list) # Will get ["a"] The cppgenerator was modified to add a verification step before trying to get the named parameter, since it could be optional and having one named parameter was assumming that all of them were provided. Change-Id: I8f379debea86b42cf89019d432e990084c9e6614 Fixes: PYSIDE-1010 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Christian Tismer <tismer@stackless.com>
| * shiboken: Improve handling of pointer types for CONVERTTOCPP in injected codeFriedemann Kleint2019-07-134-4/+47
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Code snippets like: QByteArray *cppSelf = %CONVERTTOCPP[QByteArray *](obj); cause an assert in shiboken since the '*' is captured into the target of the assignment and is not considered part of the type. Make the error message a bit clearer and add documentation. Fixes: PYSIDE-1037 Change-Id: Ie8da2f57ba91325ea677e1a00852e91726c0e09b Reviewed-by: Christian Tismer <tismer@stackless.com>
| * shiboken: List location of anonymous structs in rejected classesFriedemann Kleint2019-07-082-0/+5
| | | | | | | | | | | | | | | | Anonymous structs showed up as mysterious, empty entries in mjb_rejected_classes.log. Output the location. Change-Id: I0754e426a9fff3d1dac03aa587747ab0d7816df5 Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
* | Merge remote-tracking branch 'origin/5.12' into 5.13Friedemann Kleint2019-07-055-2954/+2990
|\| | | | | | | Change-Id: I3b3285a4e0315aea8da0426f179515866f53a7f8
| * shiboken: Move typesystem parser out of typesystem.cppFriedemann Kleint2019-07-045-2954/+2990
| | | | | | | | | | | | | | | | The file is too large to be maintainable. Task-number: PYSIDE-1024 Change-Id: I9e95ede1b7e7ce804059ef510dcec9dc9e773a48 Reviewed-by: Christian Tismer <tismer@stackless.com>
* | Merge remote-tracking branch 'origin/5.12' into 5.13Friedemann Kleint2019-07-021-5/+7
|\| | | | | | | Change-Id: I79d2166f18d8ed941c6c34fcbc7b185c2da02f0c
| * Fix qApp import of QCoreApplicationChristian Tismer2019-06-281-5/+7
| | | | | | | | | | | | | | | | | | | | The qApp fix for embedding has a recursion bug when QCoreApplication is imported. This patch avoids imports altogether and uses the already captured module, instead. Change-Id: I1af7293a31840f6b09f8611446f6f35952dedd21 Reviewed-by: Milian Wolff <milian.wolff@kdab.com>
* | Merge remote-tracking branch 'origin/5.12' into 5.13Friedemann Kleint2019-06-26106-767/+745
|\| | | | | | | Change-Id: I5bfa45782938d3bf43e16164f1ecd69f53bfcf8e
| * shiboken: Fix various clang warningsFriedemann Kleint2019-06-2531-153/+151
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Avoid copying complex types by using const ref - Use isEmpty() to check for container emptyness - Use range-based for - Use Q_DISABLE_COPY in 'public:' area - Fix spelling error - Use '= default' for trivial constructors/destructors - Remove non-null checks before deletion - Fix misleading indentation - Fix else after return - Simplify boolean expressions - Fix unused parameters, streamline code Change-Id: I8c6cadd8653e220ba8e5bdb4dd55524d13a81768 Reviewed-by: Christian Tismer <tismer@stackless.com>
| * shiboken: Replace C-style casts by C++ castsFriedemann Kleint2019-06-256-20/+19
| | | | | | | | | | | | | | | | Also change some reinterpret_cast<> to static_cast<> and use standard types for pointer arithmetics. Change-Id: Iafeeab5abffbca87d6f9767da9836bac342058c2 Reviewed-by: Christian Tismer <tismer@stackless.com>
| * shiboken: Replace 'typedef' by 'using'Friedemann Kleint2019-06-2543-145/+133
| | | | | | | | | | | | | | | | Apply Fixits by Qt Creator with some amendments. Remove iterator types by using auto instead. Change-Id: I8a75323da6ae5cdcc6b67af8be9376408953986b Reviewed-by: Christian Tismer <tismer@stackless.com>
| * shiboken: Introduce autoFriedemann Kleint2019-06-2521-128/+127
| | | | | | | | | | | | | | Apply Fixits by Qt Creator with some amendments. Change-Id: Ib2be1012ef7e8a2ad0e6cd130371bf1e941c4264 Reviewed-by: Christian Tismer <tismer@stackless.com>
| * shiboken: Introduce nullptrFriedemann Kleint2019-06-2565-278/+278
| | | | | | | | | | | | | | Apply Fixits by Qt Creator with some amendments. Change-Id: Ie8300ddb834adb8b649324562f2c912a4e8cf4ce Reviewed-by: Christian Tismer <tismer@stackless.com>
| * Cleanup pointer and trailing whitespace (omissions)Christian Tismer2019-06-251-8/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The "Cleanup pointer whitespace" patch was augmented by some C++11 changes. Unfortunately, this was done in the same commit, and so some old whitespace that was removed could re-appear invisibly, since it was in the original version. This fix tries to remove all trailing whitespace and also adds a few " *" corrections that were lost. The "type *" entries in XML files were changed back to "type*". Change-Id: Ic5c945ad64a47455fb15eebdf184b126af5ecd1d Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
| * shiboken: Introduce member initializationFriedemann Kleint2019-06-2515-35/+29
| | | | | | | | | | | | | | | | | | Use member initialization, use default bodies for constructors. Initialize missing members as reported by clang. Change-Id: Ibc51e46a37b310912ec8f274543092dfdda78e1b Reviewed-by: Christian Tismer <tismer@stackless.com>
* | Merge remote-tracking branch 'origin/5.12' into 5.13Friedemann Kleint2019-06-2450-1841/+1842
|\| | | | | | | Change-Id: Ia09beccd944e1276caa6aecbeb248e69917b7115
| * shiboken: Fix out of bounds string accessFriedemann Kleint2019-06-241-1/+1
| | | | | | | | | | | | | | | | | | | | | | Fix warning: (shiboken) Using QCharRef with an index pointing outside the valid range of a QString. The corresponding behavior is deprecated, and will be changed in a future version of Qt. introduced by qtbase/c2d2757bccc68e1b981df059786c2e76f2969530 (5.14). This happens when endPos is modified by the prior call to parseType(). Change-Id: I3b81e674c0aa118bd003aa25d8c61d89d772366f Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>