mirror of https://github.com/mono/CppSharp.git
c-sharpdotnetmonobindingsbridgecclangcpluspluscppsharpglueinteropparserparsingpinvokeswigsyntax-treevisitorsxamarinxamarin-bindings
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
31 lines
598 B
31 lines
598 B
#include "StandardLib.h" |
|
|
|
TestVectors::TestVectors() |
|
{ |
|
IntVector.push_back(2); |
|
IntVector.push_back(3); |
|
IntVector.push_back(4); |
|
|
|
IntPtrVector.push_back(&IntVector[0]); |
|
IntPtrVector.push_back(&IntVector[1]); |
|
IntPtrVector.push_back(&IntVector[2]); |
|
} |
|
|
|
std::vector<int> TestVectors::GetIntVector() |
|
{ |
|
std::vector<int> vec; |
|
vec.push_back(2); |
|
vec.push_back(3); |
|
vec.push_back(4); |
|
|
|
return vec; |
|
} |
|
|
|
int TestVectors::SumIntVector(std::vector<int>& vec) |
|
{ |
|
int sum = 0; |
|
for (unsigned I = 0, E = vec.size(); I != E; ++I) |
|
sum += vec[I]; |
|
|
|
return sum; |
|
} |