more tests

git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@5784 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
Marcelo Matus 2004-03-21 23:38:59 +00:00
commit 7e25ede10d
13 changed files with 161 additions and 18 deletions

View file

@ -28,9 +28,9 @@ double average(std::vector<int> v) {
return std::accumulate(v.begin(),v.end(),0.0)/v.size();
}
std::vector<float> half(const std::vector<float>& v) {
std::vector<float> w(v);
for (unsigned int i=0; i<w.size(); i++)
std::vector<Real> half(const std::vector<Real>& v) {
std::vector<Real> w(v);
for (std::vector<Real>::size_type i=0; i<w.size(); i++)
w[i] /= 2.0;
return w;
}