Commit d16fb74a authored by crosetto's avatar crosetto
Browse files

changing int in UInt, added a recursion in the subset method to avoid problems...

changing int in UInt, added a recursion in the subset method to avoid problems with Repeated vectors
parent c44e7059
......@@ -250,9 +250,9 @@ add(const EpetraVector& vector,
EpetraVector& EpetraVector::
subset(const EpetraVector& vector,
const int offset )
const UInt offset )
{
return this->subset(vector, getMap(), offset, 0);
return this->subset(vector, getMap(), offset, (const UInt)0);
}
EpetraVector& EpetraVector::
......@@ -261,7 +261,10 @@ subset(const EpetraVector& vector,
const UInt offset1,
const UInt offset2)
{
if (M_maptype==Repeated && vector.getMaptype()==Unique )
{
return subset(EpetraVector(vector, Repeated), map, offset1, offset2);
}
return subset(vector.M_epetraVector, map, offset1, offset2);
}
......
......@@ -143,7 +143,7 @@ public:
a) if vector has a unique map: then this should also (otherwise run time error)
b) if vector has a repeated map: then this should also. (otherwise wrong)
*/
EpetraVector& subset( const EpetraVector& vector, const int offset = 0 );
EpetraVector& subset( const EpetraVector& vector, const UInt offset = 0 );
//! set this to a subset of vector with an offset.
/*!
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment