/* * =========================================================== * testpars.c -- test the parsing functions * * Written By : D. Mazzoni March 1995 * =========================================================== */ #include #include "parser.h" /* declarations for parsing functions */ void main(int argc, char ** argv) { char caString[MaxString]; char ** cppParsedString; /* [a] : Show the command line arguments */ printf( "\n\nThe command line argument table consists of:" ); showTable( argv ); /* [b] :"Get a string. Parse it, and print the table. */ printf( "\n\nEnter a string to be parsed:" ); gets( caString ); cppParsedString = parseString( caString ); /* [c] : Print contents of the table */ showTable( cppParsedString ); /* [d] : clean up table and exit program */ printf( "\n\nFreeing up the memory in the table..." ); freeTable( cppParsedString ); printf( "\nExiting." ); }