Bug 865317 - Allow a useful NodePool::Enumerator to be constructed for an empty CC graph. r=smaug

This commit is contained in:
Andrew McCreight 2013-04-25 08:42:44 -07:00
parent 6654ca9f77
commit cbcfef43dc

View File

@ -574,7 +574,10 @@ public:
return mNext++;
}
private:
Block *mFirstBlock, *mCurBlock;
// mFirstBlock is a reference to allow an Enumerator to be constructed
// for an empty graph.
Block *&mFirstBlock;
Block *mCurBlock;
// mNext is the next value we want to return, unless mNext == mBlockEnd
// NB: mLast is a reference to allow enumerating while building!
PtrInfo *mNext, *mBlockEnd, *&mLast;