/********************************************
copyright 1991, Michael D. Brennan
This is a source file for mawk, an implementation of
the AWK programming language.
Mawk is distributed without warranty under the terms of
the GNU General Public License, version 2, 1991.
********************************************/
* Revision 5.1 91/12/05 07:59:39 brennan
/*could be STRNUM, has not been checked */
/* split on the empty string */
/* a replacement string '\&' changed to & */
/* a vector replacement -- broken on & */
#define NUM_CELL_TYPES 10
/* these defines are used to check types for two
CELLs which are adjacent in memory */
#define TWO_NOINITS (2*(1<<C_NOINIT))
#define TWO_DOUBLES (2*(1<<C_DOUBLE))
#define TWO_STRINGS (2*(1<<C_STRING))
#define TWO_STRNUMS (2*(1<<C_STRNUM))
#define TWO_MBSTRNS (2*(1<<C_MBSTRN))
#define NOINIT_AND_DOUBLE ((1<<C_NOINIT)+(1<<C_DOUBLE))
#define NOINIT_AND_STRING ((1<<C_NOINIT)+(1<<C_STRING))
#define NOINIT_AND_STRNUM ((1<<C_NOINIT)+(1<<C_STRNUM))
#define DOUBLE_AND_STRING ((1<<C_DOUBLE)+(1<<C_STRING))
#define DOUBLE_AND_STRNUM ((1<<C_STRNUM)+(1<<C_DOUBLE))
#define STRING_AND_STRNUM ((1<<C_STRING)+(1<<C_STRNUM))
#define NOINIT_AND_MBSTRN ((1<<C_NOINIT)+(1<<C_MBSTRN))
#define DOUBLE_AND_MBSTRN ((1<<C_DOUBLE)+(1<<C_MBSTRN))
#define STRING_AND_MBSTRN ((1<<C_STRING)+(1<<C_MBSTRN))
#define STRNUM_AND_MBSTRN ((1<<C_STRNUM)+(1<<C_MBSTRN))
/* number of bytes more than the characters to store a
#define STRING_OH (sizeof(STRING)-1)
short vcnt
; /* only used if type == C_REPLV */
/* all builtins are passed the evaluation stack pointer and
return its new value, here is the type */
typedef CELL
*(*PF_CP
)(CELL
*) ;
typedef CELL
*(*PF_CP
)() ;
/* an element of code (instruction) */
/* how we give parser table memory to zmalloc */