| 38 | instrumentation_(std::move(instrumentation)) {} |
| 39 | |
| 40 | absl::Status Evaluate(ExecutionFrame* frame) const override { |
| 41 | if (!frame->value_stack().HasEnough(1)) { |
| 42 | return absl::InternalError("stack underflow in instrument step."); |
| 43 | } |
| 44 | |
| 45 | return instrumentation_(expr_id_, frame->value_stack().Peek()); |
| 46 | |
| 47 | return absl::OkStatus(); |
| 48 | } |
| 49 | |
| 50 | private: |
| 51 | int64_t expr_id_; |