Fix C++ 2014 compile warnings. No functional change.

This commit is contained in:
Wilson Snyder 2015-10-04 13:41:45 -04:00
parent 4fc9a906f6
commit 7abc220fb3
8 changed files with 8 additions and 8 deletions

View File

@ -1031,7 +1031,7 @@ void AstNode::dumpTreeFile(const string& filename, bool append, bool doDump) {
if (doDump) {
{ // Write log & close
UINFO(2,"Dumping "<<filename<<endl);
const auto_ptr<ofstream> logsp (V3File::new_ofstream(filename, append));
const VL_UNIQUE_PTR<ofstream> logsp (V3File::new_ofstream(filename, append));
if (logsp->fail()) v3fatalSrc("Can't write "<<filename);
*logsp<<"Verilator Tree Dump (format 0x3900) from <e"<<dec<<editCountLast()<<">";
*logsp<<" to <e"<<dec<<editCountGbl()<<">"<<endl;

View File

@ -496,7 +496,7 @@ private:
}
string filename = v3Global.opt.makeDir()+"/"+v3Global.opt.prefix()+"__cdc_edges.txt";
const auto_ptr<ofstream> ofp (V3File::new_ofstream(filename));
const VL_UNIQUE_PTR<ofstream> ofp (V3File::new_ofstream(filename));
if (ofp->fail()) v3fatalSrc("Can't write "<<filename);
*ofp<<"Edge Report for "<<v3Global.opt.prefix()<<endl;

View File

@ -185,7 +185,7 @@ inline void V3FileDependImp::writeTimes(const string& filename, const string& cm
}
inline bool V3FileDependImp::checkTimes(const string& filename, const string& cmdlineIn) {
const auto_ptr<ifstream> ifp (V3File::new_ifstream_nodepend(filename));
const VL_UNIQUE_PTR<ifstream> ifp (V3File::new_ifstream_nodepend(filename));
if (ifp->fail()) {
UINFO(2," --check-times failed: no input "<<filename<<endl);
return false;

View File

@ -288,7 +288,7 @@ void V3Graph::dumpDotFilePrefixedAlways(const string& nameComment, bool colorAsS
void V3Graph::dumpDotFile(const string& filename, bool colorAsSubgraph) {
// This generates a file used by graphviz, http://www.graphviz.org
// "hardcoded" parameters:
const auto_ptr<ofstream> logp (V3File::new_ofstream(filename));
const VL_UNIQUE_PTR<ofstream> logp (V3File::new_ofstream(filename));
if (logp->fail()) v3fatalSrc("Can't write "<<filename);
// Header

View File

@ -140,7 +140,7 @@ void V3Hashed::dumpFilePrefixed(const string& nameComment, bool tree) {
}
void V3Hashed::dumpFile(const string& filename, bool tree) {
const auto_ptr<ofstream> logp (V3File::new_ofstream(filename));
const VL_UNIQUE_PTR<ofstream> logp (V3File::new_ofstream(filename));
if (logp->fail()) v3fatalSrc("Can't write "<<filename);
map<int,int> dist;

View File

@ -989,7 +989,7 @@ void V3Options::parseOptsFile(FileLine* fl, const string& filename, bool rel) {
// Read the specified -f filename and process as arguments
UINFO(1,"Reading Options File "<<filename<<endl);
const auto_ptr<ifstream> ifp (V3File::new_ifstream(filename));
const VL_UNIQUE_PTR<ifstream> ifp (V3File::new_ifstream(filename));
if (ifp->fail()) {
fl->v3error("Cannot open -f command file: "+filename);
return;

View File

@ -1646,7 +1646,7 @@ void OrderVisitor::process() {
m_graph.dumpDotFilePrefixed("orderg_done");
if (0 && debug()) {
string dfilename = v3Global.opt.makeDir()+"/"+v3Global.opt.prefix()+"_INT_order.tree";
const auto_ptr<ofstream> logp (V3File::new_ofstream(dfilename));
const VL_UNIQUE_PTR<ofstream> logp (V3File::new_ofstream(dfilename));
if (logp->fail()) v3fatalSrc("Can't write "<<dfilename);
m_graph.dump(*logp);
}

View File

@ -251,7 +251,7 @@ public:
if (v3Global.opt.dumpTree()) {
string filename = v3Global.debugFilename(nameComment)+".txt";
UINFO(2,"Dumping "<<filename<<endl);
const auto_ptr<ofstream> logp (V3File::new_ofstream(filename));
const VL_UNIQUE_PTR<ofstream> logp (V3File::new_ofstream(filename));
if (logp->fail()) v3fatalSrc("Can't write "<<filename);
dump(*logp, "");
}