---
name: "libmawk_set_cell"
section: "3libmawk"
platform: "linux"
package: "libmawk1t64"
version: "1.0.4-4"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/libmawk_set_cell"
---

# libmawk\_set\_cell(3libmawk)

set the value of a mawk cell.

## NAME

libmawk\_set\_cell - set the value of a mawk cell.

## SYNOPSIS

```
#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 char***argtype***, void \****argp***);**

## DESCRIPTION

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.

## SEE ALSO

**libmawk\_initialize\_stage**(3libmawk), **libmawk\_initialize**(3libmawk), **libmawk\_get\_var**(3libmawk).
