From a225318882ac0d1c48adebb27032b680788e5457 Mon Sep 17 00:00:00 2001 From: daniel Date: Sun, 23 Apr 2017 20:43:08 -0400 Subject: [PATCH] add scope resolution to parseVector --- src/Simulation.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/Simulation.cpp b/src/Simulation.cpp index 5b809d0..5a4a02d 100644 --- a/src/Simulation.cpp +++ b/src/Simulation.cpp @@ -82,7 +82,7 @@ bool Simulation::parseCircuit(string fileName) return true; } -bool parseVector(string fileName) { +bool Simulation::parseVector(string fileName) { ifstream in; in.open(fileName + "_v.txt"); if (in.fail()) { @@ -92,6 +92,7 @@ bool parseVector(string fileName) { string tmpString; int timeInt, valInt; + Wire *tmpWire; // get rid of first line getline(in, tmpString); @@ -104,7 +105,7 @@ bool parseVector(string fileName) { for(auto i = wires.begin(); i != wires.end(); ++i) { if(i->getName() == tmpString) { - tmpWire = i; + tmpWire = *i; } }