fix std::vector<const int*>, reported by tagna@gaia.ecs.csus.edu
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@9084 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
20339de8b4
commit
553c551fef
2 changed files with 11 additions and 0 deletions
|
|
@ -22,6 +22,13 @@ namespace swig {
|
|||
}
|
||||
};
|
||||
|
||||
template <class Type> struct traits_from<const Type *> {
|
||||
static PyObject *from(const Type* val) {
|
||||
return traits_from_ptr<Type>::from(const_cast<Type*>(val), 0);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
template <class Type>
|
||||
inline PyObject *from(const Type& val) {
|
||||
return traits_from<Type>::from(val);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue