GDB (API)
Defines | Typedefs | Functions | Variables
/home/stan/gdb/src/gdb/python/py-block.c File Reference
#include "defs.h"
#include "block.h"
#include "dictionary.h"
#include "symtab.h"
#include "python-internal.h"
#include "objfiles.h"

Go to the source code of this file.

Defines

#define BLPY_REQUIRE_VALID(block_obj, block)
#define BLPY_ITER_REQUIRE_VALID(block_obj)

Typedefs

typedef struct blpy_block_object block_object

Functions

PyObjectblock_to_block_object (const struct block *block, struct objfile *objfile)
struct blockblock_object_to_block (PyObject *obj)
PyObjectgdbpy_block_for_pc (PyObject *self, PyObject *args)
int gdbpy_initialize_blocks (void)

Variables

PyTypeObject block_object_type

Define Documentation

#define BLPY_ITER_REQUIRE_VALID (   block_obj)
Value:
do {                                                                    \
    if (block_obj->block == NULL)                                       \
      {                                                                 \
        PyErr_SetString (PyExc_RuntimeError,                            \
                         _("Source block for iterator is invalid."));   \
        return NULL;                                                    \
      }                                                                 \
  } while (0)

Definition at line 71 of file py-block.c.

#define BLPY_REQUIRE_VALID (   block_obj,
  block 
)
Value:
do {                                                    \
    block = block_object_to_block (block_obj);          \
    if (block == NULL)                                  \
      {                                                 \
        PyErr_SetString (PyExc_RuntimeError,            \
                         _("Block is invalid."));       \
        return NULL;                                    \
      }                                                 \
  } while (0)

Definition at line 58 of file py-block.c.


Typedef Documentation

typedef struct blpy_block_object block_object

Function Documentation

struct block* block_object_to_block ( PyObject obj) [read]

Definition at line 284 of file py-block.c.

PyObject* block_to_block_object ( const struct block block,
struct objfile objfile 
)

Definition at line 271 of file py-block.c.

PyObject* gdbpy_block_for_pc ( PyObject self,
PyObject args 
)

Definition at line 371 of file py-block.c.

Definition at line 429 of file py-block.c.


Variable Documentation

PyTypeObject block_object_type

Definition at line 480 of file py-block.c.

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Defines