9.2.2.1 sic.c amp

back: library implementation
forward: builtin.c & builtin.h
 
fastback: beginnings of a configure.in for small project
up: library implementation
fastforward: beginnings of a configure.in for small project
top: autoconf, automake, and libtool
contents: table of contents
index: index
about: about this document

9.2.2.1 `sic.c' & `sic.h'

Here are the functions for creating and managing sic parsers.

 
 #ifndef SIC_SIC_H #define SIC_SIC_H 1 #include <sic/common.h> #include <sic/error.h> #include <sic/list.h> #include <sic/syntax.h> typedef struct sic {   char *result;                 /* result string */   size_t len;                   /* bytes used by result field */   size_t lim;                   /* bytes allocated to result field */   struct builtintab *builtins;  /* tables of builtin functions */   SyntaxTable **syntax;         /* dispatch table for syntax of input */   List *syntax_init;            /* stack of syntax state initialisers */   List *syntax_finish;          /* stack of syntax state finalizers */   SicState *state;              /* state data from syntax extensions */ } Sic; #endif /* !SIC_SIC_H */ 

This structure has fields to store registered command ( builtins ) and syntax ( syntax ) handlers, along with other state information ( state ) that can be used to share information between various handlers, and some room to build a result or error string ( result ).


This document was generated by Gary V. Vaughan on May, 24 2001 using texi2html


GNU Autoconf, Automake and Libtool
GNU Autoconf, Automake, and Libtool
ISBN: 1578701902
EAN: 2147483647
Year: 2002
Pages: 290

Similar book on Amazon

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net