home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
OS/2 Shareware BBS: 8 Other
/
08-Other.zip
/
lr.zip
/
VOID.INC
< prev
next >
Wrap
Text File
|
1993-05-15
|
2KB
|
57 lines
/*
_____________________________________________________________
Void language structures
Philip R Brenan, Transcendental Automation, 1992, 800-FOR-PHIL
_____________________________________________________________
*/
#ifndef VOID_INC
#define VOID_INC
#include <stdio.h>
#include "x.inc"
#include "m.inc"
#define void_print_width 80
/*
_____________________________________________________________
Void language structures
_____________________________________________________________
*/
typedef struct VOID_PARSE
{XL ITEM; // List of items generated by this parse
M *m; // Memory used by this parse
char *s; // String to be parsed
struct VOID_ITEM *top; //Top most item
XT INDEX; // Items index
long lines; // Number of lines in source
struct VOID_ERRORS // Errors
{int count; // Number of errors detected
int required; // Closing parentheses required
int ignored; // Closing parenthesis ignored
char*ignored_text; // First closing parenthesis ignored position
int quote; // Number of closing quotes assummed
char*quote_text; // First closing quote assumed text position
} errors;
} VOID_PARSE;
typedef struct VOID_ITEM
{XL ITEM; // Sub items associated with this item
Xl item; // This item
char *s, *e, *f; // Start, end, and finish of text associated with this item
char *k; // Key of this item after editting
long line_number; // Source line number for this item
VOID_PARSE *V; // Parse containing this item
} VOID_ITEM;
/*
_____________________________________________________________
Void language procedures
_____________________________________________________________
*/
VOID_PARSE *void_parse (char *c);
void void_free (VOID_PARSE *V);
VOID_ITEM *void_find (VOID_ITEM *v, char *k);
VOID_PARSE *void_print (VOID_PARSE *V, FILE *f);
void void_test (void);
#endif