adding more tests

git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@6740 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
Marcelo Matus 2004-11-15 22:58:10 +00:00
commit e2e96ec64f
7 changed files with 42 additions and 11 deletions

View file

@ -18,7 +18,24 @@ namespace std {
%template(DoubleVector) std::vector<double>;
%template(SizeVector) std::vector<size_t>;
specialize_std_vector(size_t,PyInt_Check,PyInt_AsLong,PyInt_FromLong);
%template(sizeVector) std::vector<size_t>;
%{
template <class T>
struct Param
{
T val;
Param(T v = 0): val(v) {
}
operator T() const { return val; }
};
%}
specialize_std_vector(Param<int>,PyInt_Check,PyInt_AsLong,PyInt_FromLong);
%template(PIntVector) std::vector<Param<int> >;
%inline %{
typedef float Real;