diff --git a/clingwrapper/src/clingwrapper.cxx b/clingwrapper/src/clingwrapper.cxx index 6062c5ad..dad95b7a 100644 --- a/clingwrapper/src/clingwrapper.cxx +++ b/clingwrapper/src/clingwrapper.cxx @@ -1710,9 +1710,9 @@ std::string Cppyy::GetTypeAsString(TCppType_t type) return Cpp::GetTypeAsString(type); } -intptr_t Cppyy::GetDatamemberOffset(TCppScope_t var) +intptr_t Cppyy::GetDatamemberOffset(TCppScope_t var, TCppScope_t klass) { - return Cpp::GetVariableOffset(Cpp::GetUnderlyingScope(var)); + return Cpp::GetVariableOffset(Cpp::GetUnderlyingScope(var), klass); } // static inline diff --git a/clingwrapper/src/cpp_cppyy.h b/clingwrapper/src/cpp_cppyy.h index 70b2969a..fd6e90da 100644 --- a/clingwrapper/src/cpp_cppyy.h +++ b/clingwrapper/src/cpp_cppyy.h @@ -349,7 +349,7 @@ namespace Cppyy { RPY_EXPORTED std::string GetTypeAsString(TCppType_t type); RPY_EXPORTED - intptr_t GetDatamemberOffset(TCppScope_t var); + intptr_t GetDatamemberOffset(TCppScope_t var, TCppScope_t klass = nullptr); RPY_EXPORTED bool CheckDatamember(TCppScope_t scope, const std::string& name);