| 173 | } |
| 174 | |
| 175 | void OpBase_PropagateReset |
| 176 | ( |
| 177 | OpBase *op |
| 178 | ) { |
| 179 | // hold write operations until the read operations have been reset |
| 180 | OpBase **write_ops = array_new(OpBase *, 0); |
| 181 | |
| 182 | // reset read operations |
| 183 | _OpBase_PropagateReset(op, &write_ops); |
| 184 | |
| 185 | // reset write operations |
| 186 | uint write_op_count = array_len(write_ops); |
| 187 | for(uint i = 0; i < write_op_count; i++) { |
| 188 | OpBase *write_op = write_ops[i]; |
| 189 | OpResult res = write_op->reset(write_op); |
| 190 | ASSERT(res == OP_OK); |
| 191 | } |
| 192 | |
| 193 | array_free(write_ops); |
| 194 | } |
| 195 | |
| 196 | static void _OpBase_StatsToString |
| 197 | ( |
no test coverage detected