ENH: Updated clone function for passive/indexed particle

This commit is contained in:
andy
2010-10-25 15:57:46 +01:00
parent 51ffd56cc6
commit c85d950ee2
2 changed files with 10 additions and 4 deletions

View File

@ -108,9 +108,12 @@ public:
{}
//- Construct and return a clone
autoPtr<indexedParticle> clone() const
virtual autoPtr<Particle<indexedParticle> > clone() const
{
return autoPtr<indexedParticle>(new indexedParticle(*this));
return autoPtr<Particle<indexedParticle> >
(
new indexedParticle(*this)
);
}

View File

@ -99,9 +99,12 @@ public:
{}
//- Construct and return a clone
autoPtr<passiveParticle> clone() const
virtual autoPtr<Particle<passiveParticle> > clone() const
{
return autoPtr<passiveParticle>(new passiveParticle(*this));
return autoPtr<Particle<passiveParticle> >
(
new passiveParticle(*this)
);
}
};