STYLE: adjust ITstream naming for empty_stream()

This commit is contained in:
Mark Olesen 2023-11-17 00:13:01 +01:00
parent 636a654f4a
commit b1f9fe9d79
4 changed files with 8 additions and 5 deletions

View File

@ -478,11 +478,14 @@ int main(int argc, char *argv[])
{
auto& empty = ITstream::emptyStream();
auto& empty = ITstream::empty_stream();
Info<< "The empty stream:" << nl
<< " name: " << empty.name()
<< " good:" << empty.good()
<< " content:" << empty << nl;
const token& tok0 = empty.peek();
Info<< "First token from empty:" << tok0.info() << nl;
}
}

View File

@ -72,7 +72,7 @@ static label parseStream(ISstream& is, tokenList& tokens)
// * * * * * * * * * * * * * Static Member Functions * * * * * * * * * * * * //
Foam::ITstream& Foam::ITstream::emptyStream()
Foam::ITstream& Foam::ITstream::empty_stream()
{
if (emptyStreamPtr_)
{

View File

@ -197,9 +197,9 @@ public:
// The returned stream has no tokens and has a 'bad' state,
// to indicate that it is invalid for reading.
//
// \caution the caller can still modify the its contents,
// \caution the caller is still able to modify its contents,
// but they should not do that!
static ITstream& emptyStream();
static ITstream& empty_stream();
//- Create token list by parsing the input character sequence
//- until no good tokens remain.

View File

@ -74,7 +74,7 @@ Foam::ITstream& Foam::dictionaryEntry::stream() const
<< abort(FatalIOError);
// Need to return something - send back an empty stream
return ITstream::emptyStream();
return ITstream::empty_stream();
}