Lines Matching refs:IfStack
39 class IfStack: class
79 return abs(self._peek()) == IfStack.BRANCH_TAKEN
108 if not self._is_empty() and abs(self._peek()) in [IfStack.BRANCH_NOT_TAKEN,
109 IfStack.BRANCH_NOT_TAKEN_YET]:
110 self._push(IfStack.BRANCH_NOT_TAKEN)
112 self._push(IfStack.BRANCH_TAKEN)
114 self._push(IfStack.BRANCH_NOT_TAKEN_YET)
122 if self._peek() == IfStack.BRANCH_TAKEN:
123 self._set_last(IfStack.BRANCH_NOT_TAKEN)
124 elif self._peek() == IfStack.BRANCH_NOT_TAKEN_YET:
126 self._set_last(IfStack.BRANCH_TAKEN)
130 assert self._peek() == IfStack.BRANCH_NOT_TAKEN
138 if self._peek() in [IfStack.BRANCH_TAKEN, IfStack.BRANCH_NOT_TAKEN]:
141 self._set_last(-IfStack.BRANCH_NOT_TAKEN)
143 assert self._peek() == IfStack.BRANCH_NOT_TAKEN_YET
145 self._set_last(-IfStack.BRANCH_TAKEN)
191 self.if_stack = IfStack()