BUG: wallPoint: I/O operators missing space

This commit is contained in:
mattijs
2013-07-10 12:28:18 +01:00
parent b2fd56d54c
commit a11a6867c7
2 changed files with 7 additions and 8 deletions

View File

@ -2,7 +2,7 @@
========= | ========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration | \\ / O peration |
\\ / A nd | Copyright (C) 2011 OpenFOAM Foundation \\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation
\\/ M anipulation | \\/ M anipulation |
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
License License
@ -29,7 +29,7 @@ License
Foam::Ostream& Foam::operator<<(Foam::Ostream& os, const Foam::wallPoint& wDist) Foam::Ostream& Foam::operator<<(Foam::Ostream& os, const Foam::wallPoint& wDist)
{ {
return os << wDist.origin() << wDist.distSqr(); return os << wDist.origin() << token::SPACE << wDist.distSqr();
} }
Foam::Istream& Foam::operator>>(Foam::Istream& is, Foam::wallPoint& wDist) Foam::Istream& Foam::operator>>(Foam::Istream& is, Foam::wallPoint& wDist)

View File

@ -39,9 +39,10 @@ Ostream& operator<<
const wallPointData<Type>& wDist const wallPointData<Type>& wDist
) )
{ {
operator<<(os, static_cast<const wallPoint&>(wDist)); return os
<< static_cast<const wallPoint&>(wDist)
return os << wDist.data(); << token::SPACE
<< wDist.data();
} }
@ -52,9 +53,7 @@ Istream& operator>>
wallPointData<Type>& wDist wallPointData<Type>& wDist
) )
{ {
operator>>(is, static_cast<wallPoint&>(wDist)); return is >> static_cast<wallPoint&>(wDist) >> wDist.data_;
return is >> wDist.data_;
} }