Ruby 2.7.0p0(2019-12-25revision647ee6f091eafcce70ffb75ddf7e121e192ab217)

Data Structures | Macros | Functions
gdbm.c File Reference
`#include "ruby.h"`
`#include <gdbm.h>`
`#include <fcntl.h>`
`#include <errno.h>`

Go to the source code of this file.

## Data Structures
struct | dbmdata

## Macros
#define | TOO_LONG(n) 0
#define | RUBY_GDBM_RW_BIT 0x20000000
#define | MY_BLOCK_SIZE (2048)
#define | MY_FATAL_FUNC rb_gdbm_fatal
#define | GetDBM(obj, dbmp)
#define | GetDBM2(obj, dbmp, dbm)

## Functions
| NORETURN (static void rb_gdbm_fatal(const char *msg))
| NORETURN (static void closed_dbm(void))
void | Init_gdbm (void)

## Macro Definition Documentation

## ◆ GetDBM

#define GetDBM | ( |  | obj,
|  |  | dbmp
| ) |  |

Value:
do {\
TypedData_Get_Struct((obj), struct dbmdata, &dbm_type, (dbmp));\
if ((dbmp)->di_dbm == 0) closed_dbm();\
} while (0)

Definition at line 107 of file gdbm.c.

## ◆ GetDBM2

#define GetDBM2 | ( |  | obj,
|  |  | dbmp,
|  |  | dbm
| ) |  |

Value:
do {\
GetDBM((obj), (dbmp));\
(dbm) = (dbmp)->di_dbm;\
} while (0)

Definition at line 112 of file gdbm.c.

## ◆ MY_BLOCK_SIZE

#define MY_BLOCK_SIZE (2048)

Definition at line 84 of file gdbm.c.

## ◆ MY_FATAL_FUNC

#define MY_FATAL_FUNC rb_gdbm_fatal

Definition at line 85 of file gdbm.c.

## ◆ RUBY_GDBM_RW_BIT

#define RUBY_GDBM_RW_BIT 0x20000000

Definition at line 82 of file gdbm.c.

## ◆ TOO_LONG

#define TOO_LONG | ( |  | n | ) | 0

Definition at line 79 of file gdbm.c.

## Function Documentation

## ◆ Init_gdbm()

void Init_gdbm | ( | void |  | ) |

Definition at line 1225 of file gdbm.c.

## ◆ NORETURN() [1/2]

NORETURN | ( | static void | closed_dbmvoid | ) |

## ◆ NORETURN() [2/2]

NORETURN | ( | static void | rb_gdbm_fatalconst char *msg | ) |

obj
const VALUE VALUE obj
Definition: rb_mjit_min_header-2.7.0.h:5742
dbmdata
Definition: dbm.c:37