libmawk_set_cell3libmawk
Set the value of a mawk cell.
Usage
#include <libmawk.h> CELL *libmawk_set_cell(mawk_state_t *m, CELL *cell, const charargtype,...);
CELL *libmawk_set_cellp(mawk_state_t *m, CELL *cell, const charargtype, void *argp);
Overview
The libmawk_set_cell() function modifies the value of a mawk cell (variable). Argumetn argtype is a format character that describes the type of the payload (accessed trough vararg).
The libmawk_set_cellp() function performs the same action but accepts a generic pointer to the payload.
Format character is one of the followings:
- 'd' for int payload
- 'f' for double payload
- 's' for (zero terminated) char * payload.
-
Argument m is a libmawk context previously returned by libmawk_initialize() or libmawk_initialize_stage3().
Return value
A pointer to the cell modified.
Releases
Unchanged in 4 releases since Debian 10 (Buster).