Skip to content

Commit

Permalink
BaseTools: use iostream directly in PBlackBox
Browse files Browse the repository at this point in the history
This header is not included in any c program, and its use should not be
dependent on whether the build is using namespace std.

Signed-off-by: Dionna Glaze <[email protected]>
  • Loading branch information
deeglaze committed Jan 10, 2025
1 parent d508f68 commit 64fa43f
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions BaseTools/Source/C/VfrCompile/Pccts/h/PBlackBox.h
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,7 @@

#include "pcctscfg.h"

#include "pccts_iostream.h"

PCCTS_NAMESPACE_STD
#include <iostream>

// MR20 Added #include for "DLexerBase.h"

Expand Down Expand Up @@ -67,7 +65,7 @@ class DllExportPCCTS ParserBlackBox {
public:

ParserBlackBox(FILE *f)
: in(0)
: in(0)
, scan(0)
, tok(0)
, pipe(0)
Expand Down Expand Up @@ -101,7 +99,7 @@ class DllExportPCCTS ParserBlackBox {
, file(0)
, openByBlackBox(0)
{
FILE *f = fopen(fname, "r");
FILE *f = std::fopen(fname, "r");
if ( f==NULL ) {
openByBlackBox = 0;
std::cerr << "cannot open " << fname << "\n"; return;
Expand All @@ -123,7 +121,7 @@ class DllExportPCCTS ParserBlackBox {
{
delete in; delete scan; delete pipe; delete _parser; delete tok;
if (1 == openByBlackBox) {
fclose(file);
std::fclose(file);
}
}

Expand Down

0 comments on commit 64fa43f

Please sign in to comment.