diff --git a/src/sampling/surface/isoSurface/isoSurfaceCell.C b/src/sampling/surface/isoSurface/isoSurfaceCell.C
index d1ddb138300d40f9a64f098bbbf582a529b65f41..09b74ddbf0bd9b11cbcb5b72a002e993af42559e 100644
--- a/src/sampling/surface/isoSurface/isoSurfaceCell.C
+++ b/src/sampling/surface/isoSurface/isoSurfaceCell.C
@@ -6,7 +6,7 @@
      \\/     M anipulation  |
 -------------------------------------------------------------------------------
     Copyright (C) 2011-2016 OpenFOAM Foundation
-    Copyright (C) 2016-2019 OpenCFD Ltd.
+    Copyright (C) 2016-2020 OpenCFD Ltd.
 -------------------------------------------------------------------------------
 License
     This file is part of OpenFOAM.
@@ -1248,9 +1248,7 @@ Foam::triSurface Foam::isoSurfaceCell::subsetMesh
             if (include[oldFacei])
             {
                 // Renumber labels for face
-                const triSurface::FaceType& f = s[oldFacei];
-
-                for (const label oldPointi : f)
+                for (const label oldPointi : s[oldFacei])
                 {
                     if (oldToNewPoints[oldPointi] == -1)
                     {
diff --git a/src/sampling/surface/isoSurface/isoSurfaceTopo.H b/src/sampling/surface/isoSurface/isoSurfaceTopo.H
index 2d5bbf80fc83b7947c6ac70fc059f22afe7710fb..aa7899899e32c503834087e137c998ec21d5bb64 100644
--- a/src/sampling/surface/isoSurface/isoSurfaceTopo.H
+++ b/src/sampling/surface/isoSurface/isoSurfaceTopo.H
@@ -6,7 +6,7 @@
      \\/     M anipulation  |
 -------------------------------------------------------------------------------
     Copyright (C) 2011-2019 OpenFOAM Foundation
-    Copyright (C) 2019 OpenCFD Ltd.
+    Copyright (C) 2019-2020 OpenCFD Ltd.
 -------------------------------------------------------------------------------
 License
     This file is part of OpenFOAM.
@@ -49,6 +49,7 @@ SourceFiles
 namespace Foam
 {
 
+// Forward Declarations
 class polyMesh;
 class tetMatcher;
 
@@ -170,7 +171,7 @@ class isoSurfaceTopo
             void triangulateOutside
             (
                 const bool filterDiag,
-                const PrimitivePatch<face, SubList, const pointField&>& pp,
+                const primitivePatch& pp,
                 const boolList& pointFromDiag,
                 const labelList& pointToFace,
                 const label cellID,
diff --git a/src/surfMesh/surfaceFormats/ac3d/AC3DsurfaceFormat.C b/src/surfMesh/surfaceFormats/ac3d/AC3DsurfaceFormat.C
index 92046f20b38aa9a419c9761f8771291bc78f0fe1..ae6d279015f09422f30efecd299c2ceaf42540b2 100644
--- a/src/surfMesh/surfaceFormats/ac3d/AC3DsurfaceFormat.C
+++ b/src/surfMesh/surfaceFormats/ac3d/AC3DsurfaceFormat.C
@@ -261,17 +261,11 @@ bool Foam::fileFormats::AC3DsurfaceFormat<Face>::read
 namespace Foam
 {
 // file-scope writing of a patch of faces
-template
-<
-    class Face,
-    template<class> class FaceList,
-    class PointField,
-    class PointType
->
+template<class Patch>
 static void writeZone
 (
     Ostream& os,
-    const PrimitivePatch<Face, FaceList, PointField, PointType>& patch,
+    const Patch& patch,
     const word& name,
     const label zoneI
 )
@@ -289,7 +283,7 @@ static void writeZone
 
     os << "numsurf " << patch.size() << nl;
 
-    for (const Face& f : patch.localFaces())
+    for (const auto& f : patch.localFaces())
     {
         os  << "SURF 0x20" << nl          // polygon
             << "mat " << zoneI << nl
diff --git a/src/surfMesh/surfaceFormats/ac3d/AC3DsurfaceFormatCore.C b/src/surfMesh/surfaceFormats/ac3d/AC3DsurfaceFormatCore.C
index 10547e74d5e9fc9412f79a868c35768dcd9c7060..4e0379cad9efc704c1307419945f805aee9c4d9b 100644
--- a/src/surfMesh/surfaceFormats/ac3d/AC3DsurfaceFormatCore.C
+++ b/src/surfMesh/surfaceFormats/ac3d/AC3DsurfaceFormatCore.C
@@ -6,6 +6,7 @@
      \\/     M anipulation  |
 -------------------------------------------------------------------------------
     Copyright (C) 2011-2016 OpenFOAM Foundation
+    Copyright (C) 2020 OpenCFD Ltd.
 -------------------------------------------------------------------------------
 License
     This file is part of OpenFOAM.
@@ -28,7 +29,6 @@ License
 #include "AC3DsurfaceFormatCore.H"
 #include "clock.H"
 #include "IFstream.H"
-#include "StringStream.H"
 
 // * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
 
@@ -82,9 +82,9 @@ bool Foam::fileFormats::AC3DsurfaceFormatCore::cueTo
     string& args
 )
 {
+    string line;
     while (is.good())
     {
-        string line;
         is.getLine(line);
 
         const auto space = line.find(' ');
diff --git a/src/surfMesh/surfaceFormats/ac3d/AC3DsurfaceFormatCore.H b/src/surfMesh/surfaceFormats/ac3d/AC3DsurfaceFormatCore.H
index 3c2bc1ba558bfe66b5edacc7e303b0bc5b8fa5a5..f734fef32e78967c28345ae420027645e436b4df 100644
--- a/src/surfMesh/surfaceFormats/ac3d/AC3DsurfaceFormatCore.H
+++ b/src/surfMesh/surfaceFormats/ac3d/AC3DsurfaceFormatCore.H
@@ -6,6 +6,7 @@
      \\/     M anipulation  |
 -------------------------------------------------------------------------------
     Copyright (C) 2011-2016 OpenFOAM Foundation
+    Copyright (C) 2020 OpenCFD Ltd.
 -------------------------------------------------------------------------------
 License
     This file is part of OpenFOAM.
@@ -39,6 +40,7 @@ SourceFiles
 
 #include "Fstream.H"
 #include "surfZone.H"
+#include "StringStream.H"
 
 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
 
@@ -57,9 +59,17 @@ protected:
 
     // Protected Static Member Functions
 
-        //- Read a type via IStringStream
+        //- Read a type from string
         template<class Type>
-        static Type parse(const string& str);
+        static Type parse(const string& str)
+        {
+            IStringStream is(str);
+
+            Type t;
+            is >> t;
+
+            return t;
+        }
 
         //- Read cmd, args from IFstream
         //  The cmd is the content up to the first space, args is the balance
@@ -93,12 +103,6 @@ protected:
 
 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
 
-#ifdef NoRepository
-    #include "AC3DsurfaceFormatCoreTemplates.C"
-#endif
-
-// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
-
 #endif
 
 // ************************************************************************* //
diff --git a/src/surfMesh/surfaceFormats/ac3d/AC3DsurfaceFormatCoreTemplates.C b/src/surfMesh/surfaceFormats/ac3d/AC3DsurfaceFormatCoreTemplates.C
deleted file mode 100644
index 4208f8a052d3594db39419664c0eaffc5356f957..0000000000000000000000000000000000000000
--- a/src/surfMesh/surfaceFormats/ac3d/AC3DsurfaceFormatCoreTemplates.C
+++ /dev/null
@@ -1,45 +0,0 @@
-/*---------------------------------------------------------------------------*\
-  =========                 |
-  \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox
-   \\    /   O peration     |
-    \\  /    A nd           | www.openfoam.com
-     \\/     M anipulation  |
--------------------------------------------------------------------------------
-    Copyright (C) 2011 OpenFOAM Foundation
--------------------------------------------------------------------------------
-License
-    This file is part of OpenFOAM.
-
-    OpenFOAM is free software: you can redistribute it and/or modify it
-    under the terms of the GNU General Public License as published by
-    the Free Software Foundation, either version 3 of the License, or
-    (at your option) any later version.
-
-    OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
-    ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
-    FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
-    for more details.
-
-    You should have received a copy of the GNU General Public License
-    along with OpenFOAM.  If not, see <http://www.gnu.org/licenses/>.
-
-\*---------------------------------------------------------------------------*/
-
-#include "AC3DsurfaceFormatCore.H"
-#include "StringStream.H"
-
-// * * * * * * * * * * * * * Private Member Functions  * * * * * * * * * * * //
-
-template<class Type>
-Type Foam::fileFormats::AC3DsurfaceFormatCore::parse(const string& str)
-{
-    IStringStream is(str);
-
-    Type t;
-    is >> t;
-
-    return t;
-}
-
-
-// ************************************************************************* //