Wild Life: def_const.h File Reference

Wild Life 2.30

- Main Page
- Data Structures
- Files

- File List
- Globals

All Data Structures Files Functions Variables Typedefs Macros
Macros
def_const.h File Reference

constants More...

Go to the source code of this file.

## Macros
#define | least_sel 0
| used by collect_symbols in built_ins.c More...
#define | greatest_sel 1
| used by collect_symbols in built_ins.c More...
#define | op_sel 2
| used by collect_symbols in built_ins.c More...
#define | WFno 0
| Input failed. More...
#define | WFyes 1
| Input succeeded. More...
#define | WFmore 2
| Input succeeded with possibly more answers. More...
#define | WORDALIGN 1
| Memory Alignment. More...
#define | WORD sizeof(long)
| Memory Word Size. More...
#define | ALIGN WORD
#define | TS 1
| Time stamp technique. More...
#define | LOCALSETUP
| Enable looking first for local set_up file. More...
#define | LOCALSETUPFILE "./.set_up"
| local setup file name More...
#define | GC_THRESHOLD (alloc_words>>3)
| Garbage collection threshold (1/8 of MEM_SIZE is reasonable). More...
#define | COPY_THRESHOLD (GC_THRESHOLD>>3)
| Copy threshold (1/8 of GC_THRESHOLD is reasonable) More...
#define | REAL double
| Which C type to use to represent reals and integers in Wild_Life. More...
#define | WL_MAXINT 9007199254740991.0
| Maximum exactly representable integer (2^53-1 for double IEEE format) More...
#define | PRETTY_SIZE 20000L
| Maximum number of syntactic tokens in a pretty-printed output term. More...
#define | MAX_BUILT_INS 300L
| Maximum number of built_ins. More...
#define | STRLEN 10000L
| Maximum size of file names and input tokens (which includes input strings) (Note: calculated tokens can be arbitrarily large) More...
#define | PAGE_WIDTH 80L
| Initial page width for printing. More...
#define | PRINT_DEPTH 1000000000L
| Initial depth limit for printing. More...
#define | PRINT_SPLIT 1000000000L
| Size at which to split printing (REALs are often more precise than ints. More...
#define | PRINT_POWER 9L
| Power of ten to split printing (REALs are often more precise than ints. More...
#define | PARSER_STACK_SIZE 10000L
| Maximum depth of the parser stack. More...
#define | MAX_PRECEDENCE 1200L
| Maximum operator precedence. More...
#define | PRINT_BUFFER 100000L
| Size of print buffer. More...
#define | PROMPT "> "
| Head of prompt. More...
#define | PROMPT_BUFFER 200L
| Size of prompt buffer. More...
#define | MAX_LEVEL ((PROMPT_BUFFER-4-strlen(PROMPT))/2)
| Maximum indent level. More...
#define | XEVENTDELAY 1000L
| Maximum number of goals executed between event polling. More...
#define | MAX_TRACE_INDENT 40L
| Maximum goal indentation during tracing. More...
#define | QUOTED_TRUE 1L
| True flags for the flags field of psi-terms. More...
#define | UNFOLDED_TRUE 2L
| True flags for the flags field of psi-terms. More...
#define | TRUE 1L
| Standard boolean. More...
#define | FALSE 0L
| Standard boolean. More...
#define | TRUEMASK 1L
| Standard boolean. More...
#define | UNDEF 2L
| For LIFE boolean calculation built-in. More...
#define | NOT_CODED 0L
| For LIFE boolean calculation built-in. More...
#define | DEFRULES -1L
| Must be different from NULL, a built-in index, and a pointer Used to indicate that the rules of the definition are needed. More...
#define | EOLN 10L
| End of line. More...
#define | INT_SIZE 8*sizeof(unsigned long)
| How many types can be encoded on one integer in the transitive closure encoding. More...
#define | HEAP TRUE
| Flag to indicate heap allocation. More...
#define | STACK FALSE
| Flag to indicate stack allocation. More...
#define | FACT 100L
| Fact Kind of user input. More...
#define | QUERY 200L
| Query Kind of user input. More...
#define | ERROR 999L
| Error Kind of user input. More...
#define | RMASK 256L
| Bit mask for status field of psi-terms: RMASK is used as a flag to avoid infinite loops when tracing psi-terms. More...
#define | SMASK 255L
| Bit mask for status field of psi-terms: SMASK masks off the status bits. These are used in the 'mark' routines (copy.c) and in check_out. More...
#define | INIT_TIME_STAMP 1L
#define | psi_term_ptr 0
| values of type_ptr More...
#define | resid_ptr 1
| values of type_ptr More...
#define | int_ptr 2
| values of type_ptr More...
#define | def_ptr 3
| values of type_ptr More...
#define | code_ptr 4
| values of type_ptr More...
#define | goal_ptr 5
| values of type_ptr More...
#define | cut_ptr 6
| values of type_ptr 22.9 More...
#define | destroy_window 7+32
| To backtrack on window creation. More...
#define | show_window 8+32
| To backtrack on show window. More...
#define | hide_window 9+32
| To backtrack on hide window. More...
#define | show_subwindow 10+32
| To backtrack on show sub windows RM 8/12/92. More...
#define | hide_subwindow 11+32
| To backtrack on hide sub windows RM 8/12/92. More...
#define | undo_action 32
| Fast checking for an undo action. More...
#define | set_empty 0
| Set constants for deref_args in lefun.c. More...
#define | set_1 1
| Set constants for deref_args in lefun.c. More...
#define | set_2 2
| Set constants for deref_args in lefun.c. More...
#define | set_1_2 3
| Set constants for deref_args in lefun.c. More...
#define | set_1_2_3 7
| Set constants for deref_args in lefun.c. More...
#define | set_1_2_3_4 15
| Set constants for deref_args in lefun.c. More...
#define | NULL 0
#define | OPTIONAL 0
| for call_primitive More...
#define | REQUIRED 1
| for call_primitive More...
#define | UNEVALED (1<<1)
| for call_primitive More...
#define | JUSTFAIL (1<<2)
| for call_primitive More...
#define | POLYTYPE (1<<3)
| for call_primitive More...
#define | MANDATORY (1<<4)
| for call_primitive More...
#define | NOVALUE (1<<5)
| for call_primitive More...
#define | STREAM "stream"
| feature name More...
#define | INPUT_FILE_NAME "input_file_name"
| feature name More...
#define | LINE_COUNT "line_count"
| feature name More...
#define | START_OF_LINE "start_of_line"
| feature name More...
#define | SAVED_CHAR "saved_char"
| feature name More...
#define | OLD_SAVED_CHAR "old_saved_char"
| feature name More...
#define | SAVED_PSI_TERM "saved_psi_term"
| feature name More...
#define | OLD_SAVED_PSI_TERM "old_saved_psi_term"
| feature name More...
#define | EOF_FLAG "eof_flag"
| feature name More...
#define | CURRENT_MODULE "current_module"
| feature name More...
#define | xDefaultFont -1
#define | xDefaultLineWidth -1
#define | MAXNBARGS 20
| maximum number of arguments in builtin (only in raw or xpred) More...
#define | STRCMP 1L
| indicates to use strcmp for comparison (c function) More...
#define | INTCMP 2L
| indicates to use intcmp for comparison (in trees.c) More...
#define | FEATCMP 3L
| indicates to use featcmp for comparison (in trees.c) More...
#define | nop 0
| was enum (operator) but va_arg could not handle - now typedef More...
#define | xf 1
| was enum (operator) but va_arg could not handle - now typedef More...
#define | fx 2
| was enum (operator) but va_arg could not handle - now typedef More...
#define | yf 3
| was enum (operator) but va_arg could not handle - now typedef More...
#define | fy 4
| was enum (operator) but va_arg could not handle - now typedef More...
#define | xfx 5
| was enum (operator) but va_arg could not handle - now typedef More...
#define | xfy 6
| was enum (operator) but va_arg could not handle - now typedef More...
#define | yfx 7
| was enum (operator) but va_arg could not handle - now typedef More...
#define | fail 0L
| was enum (goal) – but must be long for error.c - now typedef More...
#define | prove 1L
| was enum (goal) – but must be long for error.c - now typedef More...
#define | unify 2L
| was enum (goal) – but must be long for error.c - now typedef More...
#define | unify_noeval 3L
| was enum (goal) – but must be long for error.c - now typedef More...
#define | disj 4L
| was enum (goal) – but must be long for error.c - now typedef More...
#define | what_next 5L
| was enum (goal) – but must be long for error.c - now typedef More...
#define | eval 6L
| was enum (goal) – but must be long for error.c - now typedef More...
#define | eval_cut 7L
| was enum (goal) – but must be long for error.c - now typedef More...
#define | freeze_cut 8L
| was enum (goal) – but must be long for error.c - now typedef More...
#define | implies_cut 9L
| was enum (goal) – but must be long for error.c - now typedef More...
#define | general_cut 10L
| was enum (goal) – but must be long for error.c - now typedef More...
#define | match 11L
| was enum (goal) – but must be long for error.c - now typedef More...
#define | type_disj 12L
| was enum (goal) – but must be long for error.c - now typedef More...
#define | clause 13L
| was enum (goal) – but must be long for error.c - now typedef More...
#define | del_clause 14L
| was enum (goal) – but must be long for error.c - now typedef More...
#define | retract 15L
| was enum (goal) – but must be long for error.c - now typedef More...
#define | load 16L
| was enum (goal) – but must be long for error.c - now typedef More...
#define | c_what_next 17L
| was enum (goal) – but must be long for error.c - now typedef More...
#define | SINFLAG 1
| flag to c_trig to compute sin More...
#define | COSFLAG 2
| flag to c_trig to compute cos More...
#define | TANFLAG 3
| flag to c_trig to compute tan More...
#define | isa_le_sel 0
| a value used in case satement in isa_select function in bi_type.c More...
#define | isa_lt_sel 1
| a value used in case satement in isa_select function in bi_type.c More...
#define | isa_ge_sel 2
| a value used in case satement in isa_select function in bi_type.c More...
#define | isa_gt_sel 3
| a value used in case satement in isa_select function in bi_type.c More...
#define | isa_eq_sel 4
| a value used in case satement in isa_select function in bi_type.c More...
#define | isa_nle_sel 5
| a value used in case satement in isa_select function in bi_type.c More...
#define | isa_nlt_sel 6
| a value used in case satement in isa_select function in bi_type.c More...
#define | isa_nge_sel 7
| a value used in case satement in isa_select function in bi_type.c More...
#define | isa_ngt_sel 8
| a value used in case satement in isa_select function in bi_type.c More...
#define | isa_neq_sel 9
| a value used in case satement in isa_select function in bi_type.c More...
#define | isa_cmp_sel 10
| a value used in case satement in isa_select function in bi_type.c More...
#define | isa_ncmp_sel 11
| a value used in case satement in isa_select function in bi_type.c More...
#define | HASHSIZE 2048L
| Size of hash table; must be a power of 2. More...
#define | NUMBUCKETS 1024L
| Total number of buckets in initial hash table;. More...
#define | HASHEND (-1)
| Tail of hash bucket. More...
#define | EXACT_FLAG 0
| flag to copy function in copy.c to indicate kind of copy More...
#define | QUOTE_FLAG 1
| flag to copy function in copy.c to indicate kind of copy More...
#define | EVAL_FLAG 2
| flag to copy function in copy.c to indicate kind of copy More...
#define | QUOTE_STUB 3
| flag having to do with copying in copy.c More...
#define | NOP 2000
| returned by precedence if token is not an operator More...
#define | DOTDOT ": " /* RM: Dec 14 1992, should be " : " */
| used in pretty printing in print.c More...
#define | NOTOP 0
| used in pretty printing in print.c More...
#define | INFIX 1
| used in pretty printing in print.c More...
#define | PREFIX 2
| used in pretty printing in print.c More...
#define | POSTFIX 3
| used in pretty printing in print.c More...
#define | stdin_fileno fileno (stdin)
#define | ARGNN 10
| primitive in sys.c does not allow more than ARGNN (10) arguments More...
#define | undef_it 1
| was enum (def_type) in extern.h now there is typedef ptr_definition More...
#define | predicate_it 2
| was enum (def_type) in extern.h now there is typedef ptr_definition More...
#define | function_it 3
| was enum (def_type) in extern.h now there is typedef ptr_definition More...
#define | type_it 4
| was enum (def_type) in extern.h now there is typedef ptr_definition More...
#define | global_it 5
| was enum (def_type) in extern.h now there is typedef ptr_definition More...

## Detailed Description

constants

Definition in file def_const.h.

## Macro Definition Documentation

#define ALIGN WORD

Definition at line 66 of file def_const.h.

#define ARGNN 10

primitive in sys.c does not allow more than ARGNN (10) arguments

Definition at line 1387 of file def_const.h.

#define c_what_next 17L

was enum (goal) – but must be long for error.c - now typedef

Definition at line 1163 of file def_const.h.

#define clause 13L

was enum (goal) – but must be long for error.c - now typedef

Definition at line 1135 of file def_const.h.

#define code_ptr 4

values of type_ptr

Definition at line 411 of file def_const.h.

#define COPY_THRESHOLD (GC_THRESHOLD>>3)

Copy threshold (1/8 of GC_THRESHOLD is reasonable)

number of words

Definition at line 125 of file def_const.h.

#define COSFLAG 2

flag to c_trig to compute cos

Definition at line 1180 of file def_const.h.

#define CURRENT_MODULE "current_module"

feature name

Definition at line 939 of file def_const.h.

#define cut_ptr 6

values of type_ptr 22.9

Definition at line 425 of file def_const.h.

#define def_ptr 3

values of type_ptr

Definition at line 404 of file def_const.h.

#define DEFRULES -1L

Must be different from NULL, a built-in index, and a pointer Used to indicate that the rules of the definition are needed.

Definition at line 302 of file def_const.h.

#define del_clause 14L

was enum (goal) – but must be long for error.c - now typedef

Definition at line 1142 of file def_const.h.

#define destroy_window 7+32

To backtrack on window creation.

Definition at line 449 of file def_const.h.

#define disj 4L

was enum (goal) – but must be long for error.c - now typedef

Definition at line 1072 of file def_const.h.

#define DOTDOT ": " /* RM: Dec 14 1992, should be " : " */

used in pretty printing in print.c

Definition at line 1346 of file def_const.h.

#define EOF_FLAG "eof_flag"

feature name

Definition at line 932 of file def_const.h.

#define EOLN 10L

End of line.

Definition at line 309 of file def_const.h.

#define ERROR 999L

Error Kind of user input.

Definition at line 352 of file def_const.h.

#define eval 6L

was enum (goal) – but must be long for error.c - now typedef

Definition at line 1086 of file def_const.h.

#define eval_cut 7L

was enum (goal) – but must be long for error.c - now typedef

Definition at line 1093 of file def_const.h.

#define EVAL_FLAG 2

flag to copy function in copy.c to indicate kind of copy

Definition at line 1320 of file def_const.h.

#define EXACT_FLAG 0

flag to copy function in copy.c to indicate kind of copy

Definition at line 1306 of file def_const.h.

#define FACT 100L

Fact Kind of user input.

Definition at line 338 of file def_const.h.

#define fail 0L

was enum (goal) – but must be long for error.c - now typedef

Definition at line 1044 of file def_const.h.

#define FALSE 0L

Standard boolean.

Definition at line 275 of file def_const.h.

#define FEATCMP 3L

indicates to use featcmp for comparison (in trees.c)

original wild_life had passed functions

Definition at line 979 of file def_const.h.

#define freeze_cut 8L

was enum (goal) – but must be long for error.c - now typedef

Definition at line 1100 of file def_const.h.

#define function_it 3

was enum (def_type) in extern.h now there is typedef ptr_definition

Definition at line 1408 of file def_const.h.

#define fx 2

was enum (operator) but va_arg could not handle - now typedef

Definition at line 1000 of file def_const.h.

#define fy 4

was enum (operator) but va_arg could not handle - now typedef

Definition at line 1014 of file def_const.h.

#define GC_THRESHOLD (alloc_words>>3)

Garbage collection threshold (1/8 of MEM_SIZE is reasonable).

number of words

Definition at line 117 of file def_const.h.

#define general_cut 10L

was enum (goal) – but must be long for error.c - now typedef

Definition at line 1114 of file def_const.h.

#define global_it 5

was enum (def_type) in extern.h now there is typedef ptr_definition

Definition at line 1422 of file def_const.h.

#define goal_ptr 5

values of type_ptr

Definition at line 418 of file def_const.h.

#define greatest_sel 1

used by collect_symbols in built_ins.c

Definition at line 18 of file def_const.h.

#define HASHEND (-1)

Tail of hash bucket.

Definition at line 1299 of file def_const.h.

#define HASHSIZE 2048L

Size of hash table; must be a power of 2.

A big hash table means it is sparse and therefore fast

Definition at line 1284 of file def_const.h.

#define HEAP TRUE

Flag to indicate heap allocation.

Definition at line 324 of file def_const.h.

#define hide_subwindow 11+32

To backtrack on hide sub windows RM 8/12/92.

Definition at line 477 of file def_const.h.

#define hide_window 9+32

To backtrack on hide window.

Definition at line 463 of file def_const.h.

#define implies_cut 9L

was enum (goal) – but must be long for error.c - now typedef

Definition at line 1107 of file def_const.h.

#define INFIX 1

used in pretty printing in print.c

Definition at line 1360 of file def_const.h.

#define INIT_TIME_STAMP 1L

Definition at line 375 of file def_const.h.

#define INPUT_FILE_NAME "input_file_name"

feature name

Definition at line 883 of file def_const.h.

#define int_ptr 2

values of type_ptr

Definition at line 397 of file def_const.h.

#define INT_SIZE 8*sizeof(unsigned long)

How many types can be encoded on one integer in the transitive closure encoding.

Definition at line 317 of file def_const.h.

#define INTCMP 2L

indicates to use intcmp for comparison (in trees.c)

original wild_life had passed functions

Definition at line 971 of file def_const.h.

#define isa_cmp_sel 10

a value used in case satement in isa_select function in bi_type.c

Definition at line 1266 of file def_const.h.

#define isa_eq_sel 4

a value used in case satement in isa_select function in bi_type.c

Definition at line 1224 of file def_const.h.

#define isa_ge_sel 2

a value used in case satement in isa_select function in bi_type.c

Definition at line 1210 of file def_const.h.

#define isa_gt_sel 3

a value used in case satement in isa_select function in bi_type.c

Definition at line 1217 of file def_const.h.

#define isa_le_sel 0

a value used in case satement in isa_select function in bi_type.c

Definition at line 1196 of file def_const.h.

#define isa_lt_sel 1

a value used in case satement in isa_select function in bi_type.c

Definition at line 1203 of file def_const.h.

#define isa_ncmp_sel 11

a value used in case satement in isa_select function in bi_type.c

Definition at line 1273 of file def_const.h.

#define isa_neq_sel 9

a value used in case satement in isa_select function in bi_type.c

Definition at line 1259 of file def_const.h.

#define isa_nge_sel 7

a value used in case satement in isa_select function in bi_type.c

Definition at line 1245 of file def_const.h.

#define isa_ngt_sel 8

a value used in case satement in isa_select function in bi_type.c

Definition at line 1252 of file def_const.h.

#define isa_nle_sel 5

a value used in case satement in isa_select function in bi_type.c

Definition at line 1231 of file def_const.h.

#define isa_nlt_sel 6

a value used in case satement in isa_select function in bi_type.c

Definition at line 1238 of file def_const.h.

#define JUSTFAIL (1<<2)

for call_primitive

When calling a primitive, you always need to process the arguments according to the same protocol. The call_primitive procedure does all this work for you. It should be called as follows:

call_primitive(f,n,args,info)

where f is the primitive implementing the actual functionality, n is the number of arguments described in args, and args is an array of argument descriptions, and info is a pointer to extra info to be passed to f. Each argument is described by a psi_arg structure whose 1st field is a string naming the feature, 2nd field is a type restriction, and 3rd field describes processing options, e.g.:

{ "1" , quoted_string , REQUIRED }

describes a required argument on feature 1, that must be a string. The 3rd field is a mask of boolean flags and is constructed by ORing some constants chosen from the set:

OPTIONAL for an optional argument REQUIRED for a required argument (i.e. residuate on it if not present UNEVALED if the argument should not be evaluated JUSTFAIL to just fail is the argument does not meet its type restriction POLYTYPE sometimes you want to permit several particular sorts in that case the 2nd psi_arg field is interpreted as a pointer to a NULL terminated array of ptr_definitions MANDATORY like REQUIRED, but it is an error for it not to be present; don't residuate. This is useful for predicates since it doesn't make sense for them to residuate. NOVALUE no value required for this argument.

The primitive must be defined to take the following arguments f(argl,result,funct[,info]) where argl is an array containing the arguments obtained by call_ primitive, result is the result in case we are implementing a function, and info (optional) is extra information, typically a pointer to a structure.

Definition at line 725 of file def_const.h.

#define least_sel 0

used by collect_symbols in built_ins.c

Definition at line 11 of file def_const.h.

#define LINE_COUNT "line_count"

feature name

Definition at line 890 of file def_const.h.

#define load 16L

was enum (goal) – but must be long for error.c - now typedef

Definition at line 1156 of file def_const.h.

#define LOCALSETUP

Enable looking first for local set_up file.

In the final release, LOCALSETUP should be undefined.

Definition at line 90 of file def_const.h.

#define LOCALSETUPFILE "./.set_up"

local setup file name

In the final release, LOCALSETUP should be undefined.

Definition at line 98 of file def_const.h.

#define MANDATORY (1<<4)

for call_primitive

When calling a primitive, you always need to process the arguments according to the same protocol. The call_primitive procedure does all this work for you. It should be called as follows:

call_primitive(f,n,args,info)

where f is the primitive implementing the actual functionality, n is the number of arguments described in args, and args is an array of argument descriptions, and info is a pointer to extra info to be passed to f. Each argument is described by a psi_arg structure whose 1st field is a string naming the feature, 2nd field is a type restriction, and 3rd field describes processing options, e.g.:

{ "1" , quoted_string , REQUIRED }

describes a required argument on feature 1, that must be a string. The 3rd field is a mask of boolean flags and is constructed by ORing some constants chosen from the set:

OPTIONAL for an optional argument REQUIRED for a required argument (i.e. residuate on it if not present UNEVALED if the argument should not be evaluated JUSTFAIL to just fail is the argument does not meet its type restriction POLYTYPE sometimes you want to permit several particular sorts in that case the 2nd psi_arg field is interpreted as a pointer to a NULL terminated array of ptr_definitions MANDATORY like REQUIRED, but it is an error for it not to be present; don't residuate. This is useful for predicates since it doesn't make sense for them to residuate. NOVALUE no value required for this argument.

The primitive must be defined to take the following arguments f(argl,result,funct[,info]) where argl is an array containing the arguments obtained by call_ primitive, result is the result in case we are implementing a function, and info (optional) is extra information, typically a pointer to a structure.

Definition at line 818 of file def_const.h.

#define match 11L

was enum (goal) – but must be long for error.c - now typedef

Definition at line 1121 of file def_const.h.

#define MAX_BUILT_INS 300L

Maximum number of built_ins.

Definition at line 154 of file def_const.h.

#define MAX_LEVEL ((PROMPT_BUFFER-4-strlen(PROMPT))/2)

Maximum indent level.

Definition at line 232 of file def_const.h.

#define MAX_PRECEDENCE 1200L

Maximum operator precedence.

Definition at line 205 of file def_const.h.

#define MAX_TRACE_INDENT 40L

Maximum goal indentation during tracing.

Definition at line 247 of file def_const.h.

#define MAXNBARGS 20

maximum number of arguments in builtin (only in raw or xpred)

Definition at line 955 of file def_const.h.

#define nop 0

was enum (operator) but va_arg could not handle - now typedef

Definition at line 986 of file def_const.h.

#define NOP 2000

returned by precedence if token is not an operator

Definition at line 1337 of file def_const.h.

#define NOT_CODED 0L

For LIFE boolean calculation built-in.

Definition at line 294 of file def_const.h.

#define NOTOP 0

used in pretty printing in print.c

Definition at line 1353 of file def_const.h.

#define NOVALUE (1<<5)

for call_primitive

When calling a primitive, you always need to process the arguments according to the same protocol. The call_primitive procedure does all this work for you. It should be called as follows:

call_primitive(f,n,args,info)

where f is the primitive implementing the actual functionality, n is the number of arguments described in args, and args is an array of argument descriptions, and info is a pointer to extra info to be passed to f. Each argument is described by a psi_arg structure whose 1st field is a string naming the feature, 2nd field is a type restriction, and 3rd field describes processing options, e.g.:

{ "1" , quoted_string , REQUIRED }

describes a required argument on feature 1, that must be a string. The 3rd field is a mask of boolean flags and is constructed by ORing some constants chosen from the set:

OPTIONAL for an optional argument REQUIRED for a required argument (i.e. residuate on it if not present UNEVALED if the argument should not be evaluated JUSTFAIL to just fail is the argument does not meet its type restriction POLYTYPE sometimes you want to permit several particular sorts in that case the 2nd psi_arg field is interpreted as a pointer to a NULL terminated array of ptr_definitions MANDATORY like REQUIRED, but it is an error for it not to be present; don't residuate. This is useful for predicates since it doesn't make sense for them to residuate. NOVALUE no value required for this argument.

The primitive must be defined to take the following arguments f(argl,result,funct[,info]) where argl is an array containing the arguments obtained by call_ primitive, result is the result in case we are implementing a function, and info (optional) is extra information, typically a pointer to a structure.

Definition at line 865 of file def_const.h.

#define NULL 0

Definition at line 533 of file def_const.h.

#define NUMBUCKETS 1024L

Total number of buckets in initial hash table;.

this is dynamically increased if necessary.

Definition at line 1292 of file def_const.h.

#define OLD_SAVED_CHAR "old_saved_char"

feature name

Definition at line 911 of file def_const.h.

#define OLD_SAVED_PSI_TERM "old_saved_psi_term"

feature name

Definition at line 925 of file def_const.h.

#define op_sel 2

used by collect_symbols in built_ins.c

Definition at line 25 of file def_const.h.

#define OPTIONAL 0

for call_primitive

When calling a primitive, you always need to process the arguments according to the same protocol. The call_primitive procedure does all this work for you. It should be called as follows:

call_primitive(f,n,args,info)

where f is the primitive implementing the actual functionality, n is the number of arguments described in args, and args is an array of argument descriptions, and info is a pointer to extra info to be passed to f. Each argument is described by a psi_arg structure whose 1st field is a string naming the feature, 2nd field is a type restriction, and 3rd field describes processing options, e.g.:

{ "1" , quoted_string , REQUIRED }

describes a required argument on feature 1, that must be a string. The 3rd field is a mask of boolean flags and is constructed by ORing some constants chosen from the set:

OPTIONAL for an optional argument REQUIRED for a required argument (i.e. residuate on it if not present UNEVALED if the argument should not be evaluated JUSTFAIL to just fail is the argument does not meet its type restriction POLYTYPE sometimes you want to permit several particular sorts in that case the 2nd psi_arg field is interpreted as a pointer to a NULL terminated array of ptr_definitions MANDATORY like REQUIRED, but it is an error for it not to be present; don't residuate. This is useful for predicates since it doesn't make sense for them to residuate. NOVALUE no value required for this argument.

The primitive must be defined to take the following arguments f(argl,result,funct[,info]) where argl is an array containing the arguments obtained by call_ primitive, result is the result in case we are implementing a function, and info (optional) is extra information, typically a pointer to a structure.

Definition at line 584 of file def_const.h.

#define PAGE_WIDTH 80L

Initial page width for printing.

Definition at line 169 of file def_const.h.

#define PARSER_STACK_SIZE 10000L

Maximum depth of the parser stack.

= maximum depth of embedded brackets etc...

Definition at line 198 of file def_const.h.

#define POLYTYPE (1<<3)

for call_primitive

When calling a primitive, you always need to process the arguments according to the same protocol. The call_primitive procedure does all this work for you. It should be called as follows:

call_primitive(f,n,args,info)

where f is the primitive implementing the actual functionality, n is the number of arguments described in args, and args is an array of argument descriptions, and info is a pointer to extra info to be passed to f. Each argument is described by a psi_arg structure whose 1st field is a string naming the feature, 2nd field is a type restriction, and 3rd field describes processing options, e.g.:

{ "1" , quoted_string , REQUIRED }

describes a required argument on feature 1, that must be a string. The 3rd field is a mask of boolean flags and is constructed by ORing some constants chosen from the set:

OPTIONAL for an optional argument REQUIRED for a required argument (i.e. residuate on it if not present UNEVALED if the argument should not be evaluated JUSTFAIL to just fail is the argument does not meet its type restriction POLYTYPE sometimes you want to permit several particular sorts in that case the 2nd psi_arg field is interpreted as a pointer to a NULL terminated array of ptr_definitions MANDATORY like REQUIRED, but it is an error for it not to be present; don't residuate. This is useful for predicates since it doesn't make sense for them to residuate. NOVALUE no value required for this argument.

The primitive must be defined to take the following arguments f(argl,result,funct[,info]) where argl is an array containing the arguments obtained by call_ primitive, result is the result in case we are implementing a function, and info (optional) is extra information, typically a pointer to a structure.

Definition at line 772 of file def_const.h.

#define POSTFIX 3

used in pretty printing in print.c

Definition at line 1374 of file def_const.h.

#define predicate_it 2

was enum (def_type) in extern.h now there is typedef ptr_definition

Definition at line 1401 of file def_const.h.

#define PREFIX 2

used in pretty printing in print.c

Definition at line 1367 of file def_const.h.

#define PRETTY_SIZE 20000L

Maximum number of syntactic tokens in a pretty-printed output term.

Definition at line 147 of file def_const.h.

#define PRINT_BUFFER 100000L

Size of print buffer.

Definition at line 211 of file def_const.h.

#define PRINT_DEPTH 1000000000L

Initial depth limit for printing.

Definition at line 176 of file def_const.h.

#define PRINT_POWER 9L

Power of ten to split printing (REALs are often more precise than ints.

Definition at line 190 of file def_const.h.

#define PRINT_SPLIT 1000000000L

Size at which to split printing (REALs are often more precise than ints.

Definition at line 183 of file def_const.h.

#define PROMPT "> "

Head of prompt.

Definition at line 218 of file def_const.h.

#define PROMPT_BUFFER 200L

Size of prompt buffer.

Definition at line 225 of file def_const.h.

#define prove 1L

was enum (goal) – but must be long for error.c - now typedef

Definition at line 1051 of file def_const.h.

#define psi_term_ptr 0

values of type_ptr

Definition at line 383 of file def_const.h.

#define QUERY 200L

Query Kind of user input.

Definition at line 345 of file def_const.h.

#define QUOTE_FLAG 1

flag to copy function in copy.c to indicate kind of copy

Definition at line 1313 of file def_const.h.

#define QUOTE_STUB 3

flag having to do with copying in copy.c

See mark_quote_c: 15.9

Definition at line 1328 of file def_const.h.

#define QUOTED_TRUE 1L

True flags for the flags field of psi-terms.

Definition at line 254 of file def_const.h.

REAL double

Which C type to use to represent reals and integers in Wild_Life.

Definition at line 132 of file def_const.h.

#define REQUIRED 1

for call_primitive

When calling a primitive, you always need to process the arguments according to the same protocol. The call_primitive procedure does all this work for you. It should be called as follows:

call_primitive(f,n,args,info)

where f is the primitive implementing the actual functionality, n is the number of arguments described in args, and args is an array of argument descriptions, and info is a pointer to extra info to be passed to f. Each argument is described by a psi_arg structure whose 1st field is a string naming the feature, 2nd field is a type restriction, and 3rd field describes processing options, e.g.:

{ "1" , quoted_string , REQUIRED }

describes a required argument on feature 1, that must be a string. The 3rd field is a mask of boolean flags and is constructed by ORing some constants chosen from the set:

OPTIONAL for an optional argument REQUIRED for a required argument (i.e. residuate on it if not present UNEVALED if the argument should not be evaluated JUSTFAIL to just fail is the argument does not meet its type restriction POLYTYPE sometimes you want to permit several particular sorts in that case the 2nd psi_arg field is interpreted as a pointer to a NULL terminated array of ptr_definitions MANDATORY like REQUIRED, but it is an error for it not to be present; don't residuate. This is useful for predicates since it doesn't make sense for them to residuate. NOVALUE no value required for this argument.

The primitive must be defined to take the following arguments f(argl,result,funct[,info]) where argl is an array containing the arguments obtained by call_ primitive, result is the result in case we are implementing a function, and info (optional) is extra information, typically a pointer to a structure.

Definition at line 631 of file def_const.h.

#define resid_ptr 1

values of type_ptr

Definition at line 390 of file def_const.h.

#define retract 15L

was enum (goal) – but must be long for error.c - now typedef

Definition at line 1149 of file def_const.h.

#define RMASK 256L

Bit mask for status field of psi-terms: RMASK is used as a flag to avoid infinite loops when tracing psi-terms.

Definition at line 359 of file def_const.h.

#define SAVED_CHAR "saved_char"

feature name

Definition at line 904 of file def_const.h.

#define SAVED_PSI_TERM "saved_psi_term"

feature name

Definition at line 918 of file def_const.h.

#define set_1 1

Set constants for deref_args in lefun.c.

Definition at line 500 of file def_const.h.

#define set_1_2 3

Set constants for deref_args in lefun.c.

Definition at line 514 of file def_const.h.

#define set_1_2_3 7

Set constants for deref_args in lefun.c.

Definition at line 521 of file def_const.h.

#define set_1_2_3_4 15

Set constants for deref_args in lefun.c.

Definition at line 528 of file def_const.h.

#define set_2 2

Set constants for deref_args in lefun.c.

Definition at line 507 of file def_const.h.

#define set_empty 0

Set constants for deref_args in lefun.c.

Definition at line 493 of file def_const.h.

#define show_subwindow 10+32

To backtrack on show sub windows RM 8/12/92.

Definition at line 470 of file def_const.h.

#define show_window 8+32

To backtrack on show window.

Definition at line 456 of file def_const.h.

#define SINFLAG 1

flag to c_trig to compute sin

Definition at line 1173 of file def_const.h.

#define SMASK 255L

Bit mask for status field of psi-terms: SMASK masks off the status bits. These are used in the 'mark' routines (copy.c) and in check_out.

Definition at line 367 of file def_const.h.

#define STACK FALSE

Flag to indicate stack allocation.

Definition at line 331 of file def_const.h.

#define START_OF_LINE "start_of_line"

feature name

Definition at line 897 of file def_const.h.

#define stdin_fileno fileno (stdin)

Definition at line 1377 of file def_const.h.

#define STRCMP 1L

indicates to use strcmp for comparison (c function)

original wild_life had passed functions

Definition at line 963 of file def_const.h.

#define STREAM "stream"

feature name

Definition at line 876 of file def_const.h.

#define STRLEN 10000L

Maximum size of file names and input tokens (which includes input strings) (Note: calculated tokens can be arbitrarily large)

Definition at line 162 of file def_const.h.

#define TANFLAG 3

flag to c_trig to compute tan

Definition at line 1187 of file def_const.h.

#define TRUE 1L

Standard boolean.

Definition at line 268 of file def_const.h.

#define TRUEMASK 1L

Standard boolean.

Definition at line 282 of file def_const.h.

#define TS 1

Time stamp technique.

Initial value of time stamp (for variable binding)

#define type_disj 12L

was enum (goal) – but must be long for error.c - now typedef

Definition at line 1128 of file def_const.h.

#define type_it 4

was enum (def_type) in extern.h now there is typedef ptr_definition

Definition at line 1415 of file def_const.h.

#define UNDEF 2L

For LIFE boolean calculation built-in.

Definition at line 288 of file def_const.h.

#define undef_it 1

was enum (def_type) in extern.h now there is typedef ptr_definition

Definition at line 1394 of file def_const.h.

#define undo_action 32

Fast checking for an undo action.

Definition at line 484 of file def_const.h.

#define UNEVALED (1<<1)

for call_primitive

When calling a primitive, you always need to process the arguments according to the same protocol. The call_primitive procedure does all this work for you. It should be called as follows:

call_primitive(f,n,args,info)

where f is the primitive implementing the actual functionality, n is the number of arguments described in args, and args is an array of argument descriptions, and info is a pointer to extra info to be passed to f. Each argument is described by a psi_arg structure whose 1st field is a string naming the feature, 2nd field is a type restriction, and 3rd field describes processing options, e.g.:

{ "1" , quoted_string , REQUIRED }

describes a required argument on feature 1, that must be a string. The 3rd field is a mask of boolean flags and is constructed by ORing some constants chosen from the set:

OPTIONAL for an optional argument REQUIRED for a required argument (i.e. residuate on it if not present UNEVALED if the argument should not be evaluated JUSTFAIL to just fail is the argument does not meet its type restriction POLYTYPE sometimes you want to permit several particular sorts in that case the 2nd psi_arg field is interpreted as a pointer to a NULL terminated array of ptr_definitions MANDATORY like REQUIRED, but it is an error for it not to be present; don't residuate. This is useful for predicates since it doesn't make sense for them to residuate. NOVALUE no value required for this argument.

The primitive must be defined to take the following arguments f(argl,result,funct[,info]) where argl is an array containing the arguments obtained by call_ primitive, result is the result in case we are implementing a function, and info (optional) is extra information, typically a pointer to a structure.

Definition at line 678 of file def_const.h.

#define UNFOLDED_TRUE 2L

True flags for the flags field of psi-terms.

Definition at line 261 of file def_const.h.

#define unify 2L

was enum (goal) – but must be long for error.c - now typedef

Definition at line 1058 of file def_const.h.

#define unify_noeval 3L

was enum (goal) – but must be long for error.c - now typedef

Definition at line 1065 of file def_const.h.

#define WFmore 2

Input succeeded with possibly more answers.

Definition at line 47 of file def_const.h.

#define WFno 0

Input failed.

Definition at line 34 of file def_const.h.

#define WFyes 1

Input succeeded.

Definition at line 41 of file def_const.h.

#define what_next 5L

was enum (goal) – but must be long for error.c - now typedef

Definition at line 1079 of file def_const.h.

#define WL_MAXINT 9007199254740991.0

Maximum exactly representable integer (2^53-1 for double IEEE format)

May be incorrect for Alpha - haven't checked. RM: Mar 1 1994

Definition at line 140 of file def_const.h.

#define WORD sizeof(long)

Memory Word Size.

Definition at line 63 of file def_const.h.

#define WORDALIGN 1

Memory Alignment.

Definition at line 56 of file def_const.h.

#define xDefaultFont -1

Definition at line 943 of file def_const.h.

#define xDefaultLineWidth -1

Definition at line 944 of file def_const.h.

#define XEVENTDELAY 1000L

Maximum number of goals executed between event polling.

Ideally, this should be a function of machine speed.

Definition at line 240 of file def_const.h.

#define xf 1

was enum (operator) but va_arg could not handle - now typedef

Definition at line 993 of file def_const.h.

#define xfx 5

was enum (operator) but va_arg could not handle - now typedef

Definition at line 1021 of file def_const.h.

#define xfy 6

was enum (operator) but va_arg could not handle - now typedef

Definition at line 1030 of file def_const.h.

#define yf 3

was enum (operator) but va_arg could not handle - now typedef

Definition at line 1007 of file def_const.h.

#define yfx 7

was enum (operator) but va_arg could not handle - now typedef

Definition at line 1037 of file def_const.h.