Update comments

pull/6897/head
Craig Tiller 9 years ago
parent 85861205dd
commit 081f1a3dbc
  1. 11
      src/core/lib/iomgr/closure.h

@ -53,8 +53,8 @@ typedef struct grpc_closure_list {
/** gRPC Callback definition. /** gRPC Callback definition.
* *
* \param arg Arbitrary input. * \param arg Arbitrary input.
* \param success An indication on the state of the iomgr. On false, cleanup * \param error GRPC_ERROR_NONE if no error occurred, otherwise some grpc_error
* actions should be taken (eg, shutdown). */ * describing what went wrong */
typedef void (*grpc_iomgr_cb_func)(grpc_exec_ctx *exec_ctx, void *arg, typedef void (*grpc_iomgr_cb_func)(grpc_exec_ctx *exec_ctx, void *arg,
grpc_error *error); grpc_error *error);
@ -66,8 +66,11 @@ struct grpc_closure {
/** Arguments to be passed to "cb". */ /** Arguments to be passed to "cb". */
void *cb_arg; void *cb_arg;
/** Once queued, the result of the closure. Before then: scratch space */
grpc_error *error; grpc_error *error;
/** Once queued, next indicates the next queued closure; before then, scratch
* space */
union { union {
grpc_closure *next; grpc_closure *next;
uintptr_t scratch; uintptr_t scratch;
@ -84,8 +87,8 @@ grpc_closure *grpc_closure_create(grpc_iomgr_cb_func cb, void *cb_arg);
#define GRPC_CLOSURE_LIST_INIT \ #define GRPC_CLOSURE_LIST_INIT \
{ NULL, NULL } { NULL, NULL }
/** add \a closure to the end of \a list and set \a closure's success to \a /** add \a closure to the end of \a list
* success */ and set \a closure's result to \a error */
void grpc_closure_list_append(grpc_closure_list *list, grpc_closure *closure, void grpc_closure_list_append(grpc_closure_list *list, grpc_closure *closure,
grpc_error *error); grpc_error *error);

Loading…
Cancel
Save