diff --git a/applications/test/stringList/Test-stringList.C b/applications/test/stringList/Test-stringList.C index 60db8cfc7c..0ed3416202 100644 --- a/applications/test/stringList/Test-stringList.C +++ b/applications/test/stringList/Test-stringList.C @@ -53,7 +53,7 @@ int main(int argc, char *argv[]) Info<< "stringList " << strLst << nl; - labelList matches = findStrings(".*ee.*", strLst); + labelList matches = findStrings(regExp(".*ee.*"), strLst); Info<< "matches found for regexp .*ee.* :" << nl << matches << nl; forAll(matches, i) @@ -71,7 +71,7 @@ int main(int argc, char *argv[]) } Info<< endl; - stringList subLst = subsetStrings(".*ee.*", strLst); + stringList subLst = subsetStrings(regExp(".*ee.*"), strLst); Info<< "subset stringList: " << subLst << nl; subLst = subsetStrings(reLst, strLst); @@ -80,7 +80,7 @@ int main(int argc, char *argv[]) inplaceSubsetStrings(reLst, strLst); Info<< "subsetted stringList: " << strLst << nl; - inplaceSubsetStrings(".*l.*", strLst); + inplaceSubsetStrings(regExp(".*l.*"), strLst); Info<< "subsetted stringList: " << strLst << nl; Info<< "\nEnd\n" << endl; diff --git a/applications/utilities/preProcessing/changeDictionary/changeDictionary.C b/applications/utilities/preProcessing/changeDictionary/changeDictionary.C index e0697c2861..5942e46429 100644 --- a/applications/utilities/preProcessing/changeDictionary/changeDictionary.C +++ b/applications/utilities/preProcessing/changeDictionary/changeDictionary.C @@ -178,7 +178,6 @@ bool addEntry } - // List of indices into thisKeys labelList findMatches ( @@ -194,19 +193,19 @@ labelList findMatches { // Wildcard match matches = findStrings(key, thisKeys); - } else if (shortcuts.size()) { // See if patchGroups expand to valid thisKeys labelList indices = findStrings(key, shortcutNames); - forAll(indices, i) + + for (const label idx : indices) { - const word& name = shortcutNames[indices[i]]; + const word& name = shortcutNames[idx]; const wordList& keys = shortcuts[name]; forAll(keys, j) { - label index = thisKeys.find(keys[j]); + const label index = thisKeys.find(keys[j]); if (index != -1) { matches.append(index); diff --git a/applications/utilities/surface/surfacePatch/surfacePatch.C b/applications/utilities/surface/surfacePatch/surfacePatch.C index 22a2bfb747..4d9ed0247f 100644 --- a/applications/utilities/surface/surfacePatch/surfacePatch.C +++ b/applications/utilities/surface/surfacePatch/surfacePatch.C @@ -137,6 +137,7 @@ int main(int argc, char *argv[]) labelList regionIDs = findStrings(regionName, surf.regions()); + if (modifier().modify(regionIDs, surf)) { changed = true; diff --git a/src/OpenFOAM/meshes/polyMesh/polyBoundaryMesh/polyBoundaryMesh.C b/src/OpenFOAM/meshes/polyMesh/polyBoundaryMesh/polyBoundaryMesh.C index 7f77ccd6f7..b1e1dac7f1 100644 --- a/src/OpenFOAM/meshes/polyMesh/polyBoundaryMesh/polyBoundaryMesh.C +++ b/src/OpenFOAM/meshes/polyMesh/polyBoundaryMesh/polyBoundaryMesh.C @@ -576,63 +576,65 @@ Foam::labelList Foam::polyBoundaryMesh::findIndices { DynamicList