Cleanup: use our utility function to create a PyUnicode from a std:str

This commit is contained in:
Campbell Barton
2025-04-01 12:33:56 +11:00
parent e3d6051181
commit 7ae020ecd1
7 changed files with 19 additions and 26 deletions

View File

@@ -357,7 +357,7 @@ PyDoc_STRVAR(
static PyObject *pygpu_interface_info_name_get(BPyGPUStageInterfaceInfo *self, void * /*closure*/)
{
StageInterfaceInfo *interface = reinterpret_cast<StageInterfaceInfo *>(self->interface);
return PyUnicode_FromString(interface->name.c_str());
return PyC_UnicodeFromStdStr(interface->name);
}
static PyGetSetDef pygpu_interface_info__tp_getseters[] = {