aboutsummaryrefslogtreecommitdiffstats
path: root/shibokengenerator.h
diff options
context:
space:
mode:
authorMarcelo Lira <marcelo.lira@openbossa.org>2010-01-14 14:45:31 -0300
committerMarcelo Lira <marcelo.lira@openbossa.org>2010-01-15 20:12:25 -0300
commit992e7170d4254257e4341d82c82aeec981396e2e (patch)
tree55c5c1ebfdb79a84f7b4a52cb5a1f80a1a44021d /shibokengenerator.h
parentd7a8026ba537a8db0fe217f5b52bcfaadaaa0265 (diff)
Values returned from C++ are now stored in a C++ variable.
The previous behaviour was to pass the result, if any, straight to the to-Python-converter method. Separating the C++ from the Python part allows us to release the thread lock when calling C++ and taking it back before calling the converter filled with Python calls. Also renamed "retvalVariableName()" to the more meaninful name "pythonReturnVariableName()" and added "cppReturnVariableName()". Also updated the type system variable replacement to recognize "%0" as "cppReturnVariableName()".
Diffstat (limited to 'shibokengenerator.h')
-rw-r--r--shibokengenerator.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/shibokengenerator.h b/shibokengenerator.h
index 666a1e07f..375863737 100644
--- a/shibokengenerator.h
+++ b/shibokengenerator.h
@@ -279,7 +279,8 @@ protected:
*/
static void initPrimitiveTypesCorrespondences();
- static QString retvalVariableName() { return QString("py_result"); }
+ static QString pythonReturnVariableName() { return QString("py_result"); }
+ static QString cppReturnVariableName() { return QString("cpp_result"); }
AbstractMetaFunctionList queryFunctions(const AbstractMetaClass* metaClass, bool allFunction = false);
void writeFunctionCall(QTextStream& s,