Fix wrong error point, bug210

This commit is contained in:
Wilson Snyder 2010-01-21 18:22:08 -05:00
parent 2da9d46ca6
commit 295faf726b

View File

@ -329,7 +329,7 @@ private:
// Has to be direct assignment without any EXTRACTing. // Has to be direct assignment without any EXTRACTing.
if (nodep->lhsp()->castVarRef() && !m_sideEffect) { if (nodep->lhsp()->castVarRef() && !m_sideEffect) {
AstVarScope* vscp = nodep->lhsp()->castVarRef()->varScopep(); AstVarScope* vscp = nodep->lhsp()->castVarRef()->varScopep();
if (!vscp) vscp->v3fatalSrc("Scope lost on variable"); if (!vscp) nodep->v3fatalSrc("Scope lost on variable");
m_lifep->simpleAssign(vscp, nodep); m_lifep->simpleAssign(vscp, nodep);
} else { } else {
nodep->lhsp()->iterateAndNext(*this); nodep->lhsp()->iterateAndNext(*this);