+/**
+ * gras_datadesc_ref_pop_arr:
+ *
+ * Most of the time, you want to include a reference in your structure which
+ * is a pointer to a dynamic array whose size is fixed by another field of
+ * your structure.
+ *
+ * This case pops up so often that this function was created to take care of
+ * this case. It creates a dynamic array type whose size is poped from the
+ * current cbps, and then create a reference to it.
+ *
+ * The name of the created datatype will be the name of the element type, with
+ * '[]*' appended to it.
+ *
+ * Then to use it, you just have to make sure that your structure pre-callback
+ * does push the size of the array in the cbps (using #gras_cbps_i_push), and
+ * you are set.
+ *
+ * But be remember that this is a stack. If you have two different pop_arr, you
+ * should push the second one first, so that the first one is on the top of the
+ * list when the first field gets transfered.
+ *
+ */
+gras_error_t
+gras_datadesc_ref_pop_arr(gras_datadesc_type_t *element_type,
+ gras_datadesc_type_t **dst) {
+ gras_error_t errcode;
+ char *name=malloc(strlen(element_type->name) + 4);
+
+ sprintf(name,"%s[]",element_type->name);
+
+ TRY(gras_datadesc_array_dyn(name,element_type,
+ gras_datadesc_cb_pop, dst));
+
+ sprintf(name,"%s[]*",element_type->name);
+ TRY(gras_datadesc_ref(name,*dst,dst));
+
+ free(name);
+
+ return no_error;
+}