SOLVED signatur von function pointer
-
hallo.
habe ein kleines problem:
../..cpp(314) : error C2664: 'qScriptRegisterMetaType' : cannot convert parameter 2 from 'QScriptValue (QScriptEngine *,const QCModelMesh *& )' to 'QScriptValue (__cdecl *)(QScriptEngine *,const T & )' with [ T=QCModelMesh * ] None of the functions with this name in scope match the target typeich übergebe eine funktionspointer mit folgender signatur:
QScriptValue (QScriptEngine *,const QCModelMesh *& )wieso passt der nicht auf die geforderte:
QScriptValue (__cdecl *)(QScriptEngine *,const T & )' with [ T=QCModelMesh * ]was mache ich da falsch?
danke schonmal!
-
Weil die Call Convention nicht passt?
-
QScriptValue (QScriptEngine *,const QCModelMesh *& )-->
QScriptValue (QScriptEngine *, QCModelMesh* const& )
-
danke, hab den fehler schon gefunden.
so bauts.
QScriptValue (QScriptEngine *, QCModelMesh * const & );mal schaun obs auch tut was es will.
irgendwie abr trotzdem seltsam, daQScriptValue (__cdecl *)(QScriptEngine *,const T & )' with [ T=QCModelMesh * ]ja schon irgendwie nach ... const QCModelMesh * & aussieht und nicht nach QCModelMesh * const &.
mal schaun obs auch tut was ich will

-
danke

camper schrieb:
QScriptValue (QScriptEngine *,const QCModelMesh *& )-->
QScriptValue (QScriptEngine *, QCModelMesh* const& )