byte.h
来自「四皇后问题」· C头文件 代码 · 共 38 行
H
38 行
/*
Little Smalltalk
Bytearray definitions
*/
struct byte_struct {
int a_ref_count;
int a_size;
int a_bsize;
uchar *a_bytes;
} ;
typedef struct byte_struct bytearray;
# define byte_value(x) (((bytearray *)(x))->a_bytes)
/*
bytearrays of size less than MAXBSAVE are kept on a free list
*/
# define MAXBSAVE 50
/*
in order to avoid a large number of small mallocs, especially
while reading the standard prelude, a fixed area of MAXBTABSIZE is
allocated and used for bytecodes until it is full. Thereafter
bytecodes are allocated using malloc. This area should be large
enough to hold at least all the bytecodes for the standard prelude.
*/
# define MAXBTABSIZE 5500
/*
for the same reason, a number of bytearrays structs are statically
allocated and placed on a free list
*/
# define MAXBYINIT 400
extern object *new_bytearray();
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?