Wild Life: templates.c File Reference

Wild Life 2.30

- Main Page
- Data Structures
- Files

- File List
- Globals

All Data Structures Files Functions Variables Typedefs Macros
Functions
templates.c File Reference

templates More...

Go to the source code of this file.

## Functions
long | get_arg (ptr_psi_term g, ptr_psi_term *arg, char *number)
| get_arg More...

## Detailed Description

templates

Definition in file templates.c.

## Function Documentation

long get_arg | ( | ptr_psi_term | g,
|  | ptr_psi_term * | arg,
|  | char * | number
| ) |  |

get_arg

Parameters

  g | - ptr_psi_term g
  arg | - ptr_psi_term *arg
  number | - char *number

GET_ARG assign the argument "number" of the goal "g" in "arg". return FALSE if bad argument.

Definition at line 25 of file templates.c.

References wl_psi_term::attr_list, wl_node::data, FALSE, FEATCMP, find(), and TRUE.

26 {
27 ptr_node n;
28
29 if ((n = find (FEATCMP, number, g->attr_list)))
30 return (*arg = (ptr_psi_term) n->data) ? TRUE: FALSE;
31 else
32 return FALSE;
33 }
FEATCMP
#define FEATCMP
indicates to use featcmp for comparison (in trees.c)
Definition: def_const.h:979
wl_psi_term
Definition: def_struct.h:177
wl_node::data
GENERIC data
Definition: def_struct.h:201
TRUE
#define TRUE
Standard boolean.
Definition: def_const.h:268
FALSE
#define FALSE
Standard boolean.
Definition: def_const.h:275
find
ptr_node find(long comp, char *keystr, ptr_node tree)
find
Definition: trees.c:394
wl_node
Definition: def_struct.h:197
wl_psi_term::attr_list
ptr_node attr_list
Definition: def_struct.h:187