Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Illegal Character "."
#2
I saved your program as "dotbug.bas". Compiling it, gives the following errors:
Quote:dotbug.bas:23: Syntax Error. Unexpected token 'a' <ID>
dotbug.bas:39: warning: Variable 'our' declared as 'float'
dotbug.bas:39: Expected a 'string' type expression, got 'float' instead
dotbug.bas:39: Unexpected "address" ID. Expected "SCREEN$" instead
dotbug.bas:41: Syntax Error. Unexpected token 'E' <ID>
dotbug.bas:44: Syntax Error. Unexpected token 'count' <ID>
dotbug.bas:48: Syntax Error. Unexpected token 'B' <ID>
dotbug.bas:52: Syntax Error. Unexpected token ';' <SC>
dotbug.bas:52: illegal character '.'
The 1st error says It gets an "unexpected 'a' token". And this is your code:
britlion Wrote:
Code:
20:     SUB putChars(x as uByte,y as uByte, width as uByte, height as uByte, dataAddress as uInteger)
21:    
22:     BLPutChar:
23:              LD      a,(IX+5)
24:              ;AND     31
25:              ld      l,a
26:              ld      a,(IX+7) ; Y value
...
This is because you forgot to add "ASM" in line 21, so the compiler thinks it's still parsing in BASIC context. Hence the syntax errors.
The "dot error" is because in BASIC context, ; does not comment the line (as you already know).

The compiler cannot report "You forgot to start 'ASM'". In fact this is why you have to write it yourself. Instead of focusing in the last error, you should pay attention to the 1st one. In many compilers, the 1st error reported is usually the most important one as subsequent errors might be a consequence of the 1st one.
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 2 Guest(s)