Commit 42807ddd authored by Mark Olesen's avatar Mark Olesen
Browse files

STYLE: fix worst spacing violations for 'os <<' constructions

- accept some violations of the coding guidelines though
- perhaps adding a style exception would be simpler.
parent 6b819eb5
......@@ -50,7 +50,7 @@ Istream& operator>>
alphaContactAngleFvPatchScalarField::interfaceThetaProps& tp
)
{
is >> tp.theta0_ >> tp.uTheta_ >> tp.thetaA_ >> tp.thetaR_;
is >> tp.theta0_ >> tp.uTheta_ >> tp.thetaA_ >> tp.thetaR_;
return is;
}
......
......@@ -59,7 +59,7 @@ public:
friend Ostream& operator<<(Ostream& os, const ent& e)
{
os << e.keyword_ << ' ' << e.i_ << endl;
os << e.keyword_ << ' ' << e.i_ << endl;
return os;
}
};
......@@ -88,7 +88,7 @@ public:
friend Ostream& operator<<(Ostream& os, const Scalar& val)
{
os << val.data_;
os << val.data_;
return os;
}
};
......
......@@ -38,7 +38,7 @@ public:
friend std::ostream& operator<<(std::ostream& os, const Vector<C>& v)
{
os << v.X << '\t' << v.Y << '\n';
os << v.X << '\t' << v.Y << '\n';
return os;
}
};
......
......@@ -89,7 +89,7 @@ int main()
{
OStringStream os;
os << table1;
os << table1;
HASHTABLE_CLASS<double> readTable(IStringStream(os.str())(), 100);
Info<< "Istream constructor:" << readTable << endl;
......
......@@ -54,7 +54,7 @@ public:
friend Ostream& operator<<(Ostream& os, const Scalar& s)
{
os << s.data_;
os << s.data_;
return os;
}
......
......@@ -60,7 +60,7 @@ public:
friend Ostream& operator<<(Ostream& os, const Scalar& val)
{
os << val.data_;
os << val.data_;
return os;
}
};
......
......@@ -83,7 +83,7 @@ int main()
{
OStringStream os;
os << table1;
os << table1;
HASHTABLE_CLASS<double> readTable(IStringStream(os.str())(), 100);
Info<< "Istream constructor:" << readTable << endl;
......
......@@ -56,7 +56,7 @@ public:
friend Ostream& operator<<(Ostream& os, const ent& e)
{
os << e.keyword_ << ' ' << e.i_ << endl;
os << e.keyword_ << ' ' << e.i_ << endl;
return os;
}
};
......
......@@ -47,8 +47,7 @@ void writeObj(Ostream& os,const pointField& points)
{
const point& pt = points[pointI];
os << "v " << pt.x() << ' ' << pt.y()
<< ' ' << pt.z() << endl;
os << "v " << pt.x() << ' ' << pt.y() << ' ' << pt.z() << endl;
}
}
......
......@@ -92,14 +92,14 @@ int main(int argc, char * argv[])
{
OSHA1stream os;
os << str;
os << str;
Info<< os.digest() << endl;
os << str;
os << str;
Info<< os.digest() << endl;
os.rewind();
os << "The quick brown fox jumps over the lazy dog";
os << "The quick brown fox jumps over the lazy dog";
Info<< os.digest() << endl;
}
......
......@@ -110,9 +110,9 @@ const labelListListList& block::boundaryPatches() const
Ostream& operator<<(Ostream& os, const block& b)
{
os << b.Vertices << nl
<< b.Cells << nl
<< b.BoundaryPatches << endl;
os << b.Vertices << nl
<< b.Cells << nl
<< b.BoundaryPatches << endl;
return os;
}
......
......@@ -57,7 +57,7 @@ void hexBlock::readPoints(Istream& is)
{
forAll(points_, i)
{
is >> points_[i].x() >> points_[i].y() >> points_[i].z();
is >> points_[i].x() >> points_[i].y() >> points_[i].z();
}
// Calculate the handedness of the block
......
......@@ -128,13 +128,13 @@ void hexBlock::readPoints
Info<< "Reading " << nPoints << " x coordinates..." << endl;
for (label i=0; i < nPoints; i++)
{
is >> points_[i].x();
is >> points_[i].x();
}
Info<< "Reading " << nPoints << " y coordinates..." << endl;
for (label i=0; i < nPoints; i++)
{
is >> points_[i].y();
is >> points_[i].y();
}
if (twoDThicknes > 0)
......@@ -156,7 +156,7 @@ void hexBlock::readPoints
Info<< "Reading " << nPoints << " z coordinates..." << endl;
for (label i=0; i < nPoints; i++)
{
is >> points_[i].z();
is >> points_[i].z();
}
}
......@@ -166,7 +166,7 @@ void hexBlock::readPoints
Info<< "Reading " << nPoints << " blanks..." << endl;
for (label i=0; i < nPoints; i++)
{
is >> iBlank;
is >> iBlank;
}
}
......
......@@ -51,7 +51,7 @@ using namespace Foam;
void writeOBJ(const point& pt, Ostream& os)
{
os << "v " << pt.x() << ' ' << pt.y() << ' ' << pt.z() << nl;
os << "v " << pt.x() << ' ' << pt.y() << ' ' << pt.z() << nl;
}
// All edges of mesh
......
......@@ -58,7 +58,7 @@ Foam::Ostream& Foam::operator<<
if (faceI != -1)
{
os<< " fc:" << c.patch_.localFaces()[faceI].centre(pts);
os << " fc:" << c.patch_.localFaces()[faceI].centre(pts);
}
return os;
}
......
......@@ -974,7 +974,7 @@ int main(int argc, char *argv[])
IStringStream is(rawLine + ' ');
// Type: cellSet, faceSet, pointSet, faceZoneSet
is >> setType;
is >> setType;
stat = parseType(runTime, mesh, setType, is);
......
......@@ -85,20 +85,20 @@ void Foam::writeFuns::write
fField.size()*sizeof(float)
);
os << std::endl;
os << std::endl;
}
else
{
forAll(fField, i)
{
os << fField[i] << ' ';
os << fField[i] << ' ';
if (i > 0 && (i % 10) == 0)
{
os << std::endl;
os << std::endl;
}
}
os << std::endl;
os << std::endl;
}
}
......@@ -134,20 +134,20 @@ void Foam::writeFuns::write
elems.size()*sizeof(label)
);
os << std::endl;
os << std::endl;
}
else
{
forAll(elems, i)
{
os << elems[i] << ' ';
os << elems[i] << ' ';
if (i > 0 && (i % 10) == 0)
{
os << std::endl;
os << std::endl;
}
}
os << std::endl;
os << std::endl;
}
}
......
......@@ -85,12 +85,12 @@ void writeBytes(char* start, int nBytes)
// Debug: write wall flags data
void writeWallFlags(Ostream& os, label cellI, const labelList& wallFlags)
{
os << "cell " << cellI << " wallsFlags:";
os << "cell " << cellI << " wallsFlags:";
forAll(wallFlags, wallFaceI)
{
os << wallFlags[wallFaceI] << " ";
os << wallFlags[wallFaceI] << ' ';
}
os << endl;
os << endl;
}
......
......@@ -99,12 +99,12 @@ void print(const char* msg, Ostream& os, const PtrList<GeoField>& flds)
{
if (flds.size())
{
os << msg;
os << msg;
forAll(flds, i)
{
os<< ' ' << flds[i].name();
os << ' ' << flds[i].name();
}
os << endl;
os << endl;
}
}
......@@ -113,9 +113,9 @@ void print(Ostream& os, const wordList& flds)
{
forAll(flds, i)
{
os<< ' ' << flds[i];
os << ' ' << flds[i];
}
os << endl;
os << endl;
}
......
......@@ -163,12 +163,12 @@ void print(const char* msg, Ostream& os, const PtrList<GeoField>& flds)
{
if (flds.size())
{
os << msg;
os << msg;
forAll(flds, i)
{
os<< ' ' << flds[i].name();
os << ' ' << flds[i].name();
}
os << endl;
os << endl;
}
}
......@@ -177,9 +177,9 @@ void print(Ostream& os, const wordList& flds)
{
forAll(flds, i)
{
os<< ' ' << flds[i];
os << ' ' << flds[i];
}
os << endl;
os << endl;
}
......
Markdown is supported
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