aboutsummaryrefslogtreecommitdiffstats
path: root/sources/shiboken2/libshiboken/sbkstring.cpp
diff options
context:
space:
mode:
authorFriedemann Kleint <Friedemann.Kleint@qt.io>2020-09-17 07:56:30 +0200
committerFriedemann Kleint <Friedemann.Kleint@qt.io>2020-09-17 08:22:55 +0200
commit4c5e405e691f707f2765b5f920c28213a36d22e5 (patch)
tree48000f220fc2c4365b276146e3d08a05c3a90312 /sources/shiboken2/libshiboken/sbkstring.cpp
parent53181fb95d3884cc067d005f37accd92d128bccc (diff)
parent38814354ff6a30258b79947304fd3a6be4dc7089 (diff)
Merge remote-tracking branch 'origin/5.15' into dev
Diffstat (limited to 'sources/shiboken2/libshiboken/sbkstring.cpp')
-rw-r--r--sources/shiboken2/libshiboken/sbkstring.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/sources/shiboken2/libshiboken/sbkstring.cpp b/sources/shiboken2/libshiboken/sbkstring.cpp
index 2aae183fe..fff9d05ec 100644
--- a/sources/shiboken2/libshiboken/sbkstring.cpp
+++ b/sources/shiboken2/libshiboken/sbkstring.cpp
@@ -266,5 +266,13 @@ PyObject *getSnakeCaseName(const char *name, bool lower)
return createStaticString(new_name);
}
+PyObject *getSnakeCaseName(PyObject *name, bool lower)
+{
+ // This is all static strings, not refcounted.
+ if (lower)
+ return getSnakeCaseName(toCString(name), lower);
+ return name;
+}
+
} // namespace String
} // namespace Shiboken