| 172 | } |
| 173 | |
| 174 | Maybe<void> BusyWaitAndCheck(std::shared_ptr<CheckConsistencyAsyncTransportCtx>& ctx) { |
| 175 | JUST_MSG(ctx->WaitDone(), kAsymmetricCodeErrorMsg); |
| 176 | JUST(ctx->Check()); |
| 177 | return Maybe<void>::Ok(); |
| 178 | } |
| 179 | |
| 180 | Maybe<void> RunCallback(const std::shared_ptr<one::Tensor>& tensor, |
| 181 | const std::function<Maybe<void>()>& Callback) { |