# ldump.c File Reference

`#include <stddef.h>`
`#include "lua.h"`
`#include "lobject.h"`
`#include "lstate.h"`
`#include "lundump.h"`

## Classes
struct | DumpState
## Defines
#define | ldump_c
#define | LUA_CORE
#define | DumpMem(b, n, size, D) DumpBlock(b,(n)*(size),D)
#define | DumpVar(x, D) DumpMem(&x,1,sizeof(x),D)
#define | DumpCode(f, D) DumpVector(f->code,f->sizecode,sizeof(Instruction),D)
## Functions
static void | DumpBlock (const void *b, size_t size, DumpState *D)
static void | DumpChar (int y, DumpState *D)
static void | DumpInt (int x, DumpState *D)
static void | DumpNumber (lua_Number x, DumpState *D)
static void | DumpVector (const void *b, int n, size_t size, DumpState *D)
static void | DumpString (const TString *s, DumpState *D)
static void | DumpFunction (const Proto *f, const TString *p, DumpState *D)
static void | DumpConstants (const Proto *f, DumpState *D)
static void | DumpDebug (const Proto *f, DumpState *D)
static void | DumpHeader (DumpState *D)
int | luaU_dump (lua_State *L, const Proto *f, lua_Writer w, void *data, int strip)

## Define Documentation

#define DumpCode | ( | f,
|  | D |  | ) | DumpVector(f->code,f->sizecode,sizeof(Instruction),D)

#define DumpMem | ( | b,
|  | n,
|  | size,
|  | D |  | ) | DumpBlock(b,(n)*(size),D)

#define DumpVar | ( | x,
|  | D |  | ) | DumpMem(&x,1,sizeof(x),D)

#define ldump_c

#define LUA_CORE

## Function Documentation

static void DumpBlock | ( | const void * | b,
|  | size_t | size,
|  | DumpState * | D |
| ) |  |  | `[static]`

static void DumpChar | ( | int | y,
|  | DumpState * | D |
| ) |  |  | `[static]`

static void DumpConstants | ( | const Proto * | f,
|  | DumpState * | D |
| ) |  |  | `[static]`

static void DumpDebug | ( | const Proto * | f,
|  | DumpState * | D |
| ) |  |  | `[static]`

static void DumpFunction | ( | const Proto * | f,
|  | const TString * | p,
|  | DumpState * | D |
| ) |  |  | `[static]`

static void DumpHeader | ( | DumpState * | D | ) | `[static]`

static void DumpInt | ( | int | x,
|  | DumpState * | D |
| ) |  |  | `[static]`

static void DumpNumber | ( | lua_Number | x,
|  | DumpState * | D |
| ) |  |  | `[static]`

static void DumpString | ( | const TString * | s,
|  | DumpState * | D |
| ) |  |  | `[static]`

static void DumpVector | ( | const void * | b,
|  | int | n,
|  | size_t | size,
|  | DumpState * | D |
| ) |  |  | `[static]`

int luaU_dump | ( | lua_State * | L,
|  | const Proto * | f,
|  | lua_Writer | w,
|  | void * | data,
|  | int | strip |
| ) |  |  |