pike.git
/
src
/
program.h
version
»
Context lines:
10
20
40
80
file
none
3
pike.git/src/program.h:1:
/*\ ||| This file a part of Pike, and is copyright by Fredrik Hubinette ||| Pike is distributed as GPL (General Public License) ||| See the files COPYING and DISCLAIMER for more information. \*/ /*
-
* $Id: program.h,v 1.
117
2001/
02
/
24
18
:
23
:
15
grubba
Exp $
+
* $Id: program.h,v 1.
118
2001/
03
/
12
22
:
42
:
19
hubbe
Exp $
*/ #ifndef PROGRAM_H #define PROGRAM_H #include <stdarg.h> #include "global.h" #include "pike_types.h" #include "pike_macros.h" #include "svalue.h" #include "time_stuff.h"
pike.git/src/program.h:247:
/* Objects should not be destructed even when they only has weak * references left. */ #define PROGRAM_NO_WEAK_FREE 256 /* Objects should not be destructed by f_destruct(). */ #define PROGRAM_NO_EXPLICIT_DESTRUCT 512 /* Program is in an inconsistant state */ #define PROGRAM_AVOID_CHECK 512
+
enum pike_program_event
+
{
+
PROG_EVENT_INIT =0,
+
PROG_EVENT_EXIT,
+
PROG_EVENT_GC_RECURSE,
+
PROG_EVENT_GC_CHECK,
+
NUM_PROG_EVENTS,
+
};
struct program { INT32 refs; #ifdef PIKE_SECURITY struct object *prot; #endif INT32 id; /* used to identify program in caches */ INT32 parent_program_id; /* storage_needed - storage needed in object struct
pike.git/src/program.h:268:
* subtracted when inheriting. */ ptrdiff_t storage_needed; /* storage needed in the object struct */ INT16 flags; /* PROGRAM_* */ unsigned INT8 alignment_needed; struct timeval timestamp; struct program *next; struct program *prev;
-
void (*
init)(struct object *);
-
void (*exit)(struct object *);
-
void (*gc
_
recurse_func
)(
struct
object *);
-
void (*gc
_
check
_
func
)
(struct object *)
;
+
void (*
event
_
handler
)(
enum
pike
_
program
_
event
);
#ifdef PIKE_DEBUG unsigned INT32 checksum; #endif #ifdef PROFILING unsigned INT32 num_clones; #endif /* PROFILING */ size_t total_size; #define FOO(NUMTYPE,TYPE,NAME) TYPE * NAME ;