aboutsummaryrefslogtreecommitdiffstats
path: root/sources/pyside6/libpysideqml/pysideqmlforeign.cpp
diff options
context:
space:
mode:
authorFriedemann Kleint <Friedemann.Kleint@qt.io>2024-06-18 13:10:15 +0200
committerFriedemann Kleint <Friedemann.Kleint@qt.io>2024-06-24 10:36:15 +0200
commitd326e40e8c52c9f74b6baa0d6f7f9a54ded0172a (patch)
treea459a06eafb612cd51fbff447f63b4e1b9772422 /sources/pyside6/libpysideqml/pysideqmlforeign.cpp
parent1a4593f940b0eca4d0756092ed34c2b6a6962bd6 (diff)
libpysideqml: Fix static analysis warnings
- Initialize variables - Use auto * - Use nullptr - Remove repeated return types - Minor cleanups Change-Id: I26cacce81a4c8ebc885f8c34d59fdac5d0026af9 Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io>
Diffstat (limited to 'sources/pyside6/libpysideqml/pysideqmlforeign.cpp')
-rw-r--r--sources/pyside6/libpysideqml/pysideqmlforeign.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/sources/pyside6/libpysideqml/pysideqmlforeign.cpp b/sources/pyside6/libpysideqml/pysideqmlforeign.cpp
index 18d39d121..90136f0aa 100644
--- a/sources/pyside6/libpysideqml/pysideqmlforeign.cpp
+++ b/sources/pyside6/libpysideqml/pysideqmlforeign.cpp
@@ -35,7 +35,7 @@ PyObject *PySideQmlForeignPrivate::tp_call(PyObject *self, PyObject *args, PyObj
info->foreignType = data->type();
// Insert an alias to be used by the factory functions of Decorators like
// @QmlExtended and @QmlAttached.
- auto *foreignObj = reinterpret_cast<const PyObject *>(info->foreignType);
+ const auto *foreignObj = reinterpret_cast<const PyObject *>(info->foreignType);
PySide::Qml::insertQmlTypeInfoAlias(foreignObj, info);
Py_INCREF(klass);
@@ -49,7 +49,7 @@ const char *PySideQmlForeignPrivate::name() const
extern "C" {
-static PyTypeObject *createPySideQmlForeignType(void)
+static PyTypeObject *createPySideQmlForeignType()
{
auto typeSlots =
PySide::ClassDecorator::Methods<PySideQmlForeignPrivate>::typeSlots();