Fixed a problem with --feature labels_without_colons: The scanner inserts

a space at the beginning of a new file, with the assumption that this is a
"neutral" character. If above feature is enabled, it is no longer neutral,
so read the first character from the new input instead.


git-svn-id: svn://svn.cc65.org/cc65/trunk@3650 b7a2c559-68d2-44c3-8de9-860c34a00d81
This commit is contained in:
cuz
2005-11-20 12:30:24 +00:00
parent 8634943406
commit 69485b5000

View File

@@ -364,10 +364,12 @@ void NewInputFile (const char* Name)
IFile = I; IFile = I;
++ICount; ++ICount;
/* Setup the next token and character so it will be skipped on the /* Read the first character from the new file */
* next call to NextRawTok(). NextChar ();
/* Setup the next token so it will be skipped on the next call to
* NextRawTok().
*/ */
C = ' ';
Tok = TOK_SEP; Tok = TOK_SEP;
} }
@@ -413,10 +415,12 @@ void NewInputData (char* Data, int Malloced)
I->Next = IData; I->Next = IData;
IData = I; IData = I;
/* Setup the next token and character so it will be skipped on the /* Read the first character from the new file */
* next call to NextRawTok(). NextChar ();
/* Setup the next token so it will be skipped on the next call to
* NextRawTok().
*/ */
C = ' ';
Tok = TOK_SEP; Tok = TOK_SEP;
} }