Use cc65 character classification routines
git-svn-id: svn://svn.cc65.org/cc65/trunk@1245 b7a2c559-68d2-44c3-8de9-860c34a00d81
This commit is contained in:
@@ -40,6 +40,7 @@
|
|||||||
#include <ctype.h>
|
#include <ctype.h>
|
||||||
|
|
||||||
/* common */
|
/* common */
|
||||||
|
#include "chartype.h"
|
||||||
#include "xsprintf.h"
|
#include "xsprintf.h"
|
||||||
|
|
||||||
/* ld65 */
|
/* ld65 */
|
||||||
@@ -177,11 +178,11 @@ Again:
|
|||||||
CfgErrorCol = InputCol;
|
CfgErrorCol = InputCol;
|
||||||
|
|
||||||
/* Identifier? */
|
/* Identifier? */
|
||||||
if (C == '_' || isalpha (C)) {
|
if (C == '_' || IsAlpha (C)) {
|
||||||
|
|
||||||
/* Read the identifier */
|
/* Read the identifier */
|
||||||
I = 0;
|
I = 0;
|
||||||
while (C == '_' || isalnum (C)) {
|
while (C == '_' || IsAlNum (C)) {
|
||||||
if (I < CFG_MAX_IDENT_LEN) {
|
if (I < CFG_MAX_IDENT_LEN) {
|
||||||
CfgSVal [I++] = C;
|
CfgSVal [I++] = C;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -40,6 +40,7 @@
|
|||||||
#include <ctype.h>
|
#include <ctype.h>
|
||||||
|
|
||||||
/* common */
|
/* common */
|
||||||
|
#include "chartype.h"
|
||||||
#include "xsprintf.h"
|
#include "xsprintf.h"
|
||||||
|
|
||||||
/* ld65 */
|
/* ld65 */
|
||||||
@@ -177,11 +178,11 @@ Again:
|
|||||||
CfgErrorCol = InputCol;
|
CfgErrorCol = InputCol;
|
||||||
|
|
||||||
/* Identifier? */
|
/* Identifier? */
|
||||||
if (C == '_' || isalpha (C)) {
|
if (C == '_' || IsAlpha (C)) {
|
||||||
|
|
||||||
/* Read the identifier */
|
/* Read the identifier */
|
||||||
I = 0;
|
I = 0;
|
||||||
while (C == '_' || isalnum (C)) {
|
while (C == '_' || IsAlNum (C)) {
|
||||||
if (I < CFG_MAX_IDENT_LEN) {
|
if (I < CFG_MAX_IDENT_LEN) {
|
||||||
CfgSVal [I++] = C;
|
CfgSVal [I++] = C;
|
||||||
}
|
}
|
||||||
@@ -520,7 +521,7 @@ void CfgOpenInput (void)
|
|||||||
|
|
||||||
/* Initialize variables */
|
/* Initialize variables */
|
||||||
C = ' ';
|
C = ' ';
|
||||||
InputLine = 1;
|
InputLine = 1;
|
||||||
InputCol = 0;
|
InputCol = 0;
|
||||||
|
|
||||||
/* Start the ball rolling ... */
|
/* Start the ball rolling ... */
|
||||||
|
|||||||
@@ -40,6 +40,7 @@
|
|||||||
#include <ctype.h>
|
#include <ctype.h>
|
||||||
|
|
||||||
/* common */
|
/* common */
|
||||||
|
#include "chartype.h"
|
||||||
#include "xsprintf.h"
|
#include "xsprintf.h"
|
||||||
|
|
||||||
/* sim65 */
|
/* sim65 */
|
||||||
@@ -176,11 +177,11 @@ Again:
|
|||||||
CfgErrorCol = InputCol;
|
CfgErrorCol = InputCol;
|
||||||
|
|
||||||
/* Identifier? */
|
/* Identifier? */
|
||||||
if (C == '_' || isalpha (C)) {
|
if (C == '_' || IsAlpha (C)) {
|
||||||
|
|
||||||
/* Read the identifier */
|
/* Read the identifier */
|
||||||
I = 0;
|
I = 0;
|
||||||
while (C == '_' || isalnum (C)) {
|
while (C == '_' || IsAlNum (C)) {
|
||||||
if (I < CFG_MAX_IDENT_LEN) {
|
if (I < CFG_MAX_IDENT_LEN) {
|
||||||
CfgSVal [I++] = C;
|
CfgSVal [I++] = C;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user