Use new last() method for List-type classes

- use first() method in some places as well where it helps clarity

- there are a few remaining cases: git grep 'size()-1]'
This commit is contained in:
Mark Olesen
2009-11-26 13:35:57 +01:00
parent b2d7439b86
commit d17d015f88
45 changed files with 121 additions and 124 deletions

View File

@ -1276,7 +1276,7 @@ bool Foam::polyMeshGeometry::checkFaceAngles
faceNormal /= mag(faceNormal) + VSMALL;
// Get edge from f[0] to f[size-1];
vector ePrev(p[f[0]] - p[f[f.size()-1]]);
vector ePrev(p[f.first()] - p[f.last()]);
scalar magEPrev = mag(ePrev);
ePrev /= magEPrev + VSMALL;