(op)
| 88 | |
| 89 | |
| 90 | def _is_stateful_pfor_op(op): |
| 91 | if isinstance(op, WhileOp): |
| 92 | return op.is_stateful |
| 93 | if op.type == "Const": |
| 94 | # Const didn't have an op_def. |
| 95 | return False |
| 96 | if op.type in passthrough_stateful_ops: |
| 97 | return False |
| 98 | assert hasattr(op, "op_def") and op.op_def is not None, op |
| 99 | return op.op_def.is_stateful |
| 100 | |
| 101 | |
| 102 | # pylint: disable=protected-access |
no outgoing calls
no test coverage detected