/*====================================================================*
*
* bool istoken (SCAN * content, const char *literal);
*
* scan.h
*
* return true if the current token substring matches the given literal
* string; comparison is case sensitive;
*
*. Motley Tools by Charles Maier <cmaier@cmassoc.net>;
*: Published 2001-2006 by Charles Maier Associates Limited;
*; Released under the GNU General Public Licence v2 and later;
*
*--------------------------------------------------------------------*/
#ifndef ISTOKEN_SOURCE
#define ISTOKEN_SOURCE
#include <ctype.h>
#include "../scan/scan.h"
bool istoken (SCAN * content, const char *literal)
{
const char * current = content->first;
while ((current < content->final) && (*current == *literal))
{
current++;
literal++;
}
return (*literal == (char)(0));
}
#endif