aboutsummaryrefslogtreecommitdiffstats
path: root/sources/pyside6/libpyside/pysideproperty.cpp
diff options
context:
space:
mode:
authorFriedemann Kleint <Friedemann.Kleint@qt.io>2023-09-18 09:55:49 +0200
committerFriedemann Kleint <Friedemann.Kleint@qt.io>2023-09-20 13:44:47 +0200
commit2cc7ded80caa506263ba2c9fd87db76dae71956a (patch)
tree353da05cded3d6ca9dd0efa5d4cb4a34e0dc57bf /sources/pyside6/libpyside/pysideproperty.cpp
parentc47bc0eea7348020d748f67555f60542ff496c0a (diff)
Fix namespaces
- Use nested namespaces instead repetitive namespace declaration - Remove anonymous namespaces that contain only static functions. "static" is sufficient here, the anonymous namespace only increases compilation time. Pick-to: 6.6 6.5 Change-Id: I6cd1b63da79eaf40a1b7ae031def97fa22903e99 Reviewed-by: Shyamnath Premnadh <Shyamnath.Premnadh@qt.io>
Diffstat (limited to 'sources/pyside6/libpyside/pysideproperty.cpp')
-rw-r--r--sources/pyside6/libpyside/pysideproperty.cpp10
1 files changed, 2 insertions, 8 deletions
diff --git a/sources/pyside6/libpyside/pysideproperty.cpp b/sources/pyside6/libpyside/pysideproperty.cpp
index 4bc5f5b16..8c0f51e57 100644
--- a/sources/pyside6/libpyside/pysideproperty.cpp
+++ b/sources/pyside6/libpyside/pysideproperty.cpp
@@ -440,8 +440,6 @@ static int qpropertyClear(PyObject *self)
} // extern "C"
-namespace {
-
static PyObject *getFromType(PyTypeObject *type, PyObject *name)
{
PyObject *attr = nullptr;
@@ -459,10 +457,7 @@ static PyObject *getFromType(PyTypeObject *type, PyObject *name)
return attr;
}
-} //namespace
-
-
-namespace PySide { namespace Property {
+namespace PySide::Property {
static const char *Property_SignatureStrings[] = {
"PySide6.QtCore.Property(self,type:type,fget:typing.Callable=None,fset:typing.Callable=None,"
@@ -595,5 +590,4 @@ PyObject *getTypeObject(const PySideProperty *self)
return self->d->pyTypeObject;
}
-} //namespace Property
-} //namespace PySide
+} //namespace PySide::Property