Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
BorIDE ASM compilation error
#1
Hi all

I'm trying to compile a piece os ASM in BorIDE. The code is:

ASM
[2746 lines of ASM]
END ASM

When I try to compile it, I always have the same error (check image) The point is that no matter if I add or remove lines from the code, the error is always the same and always in the same line (1917) Anybody know if it's a bug? Maybe there are too many lines of code?

Thanks and regards

EDIT: the error is not generated by BorIDE but the zxb.exe compiler, sorry.


Attached Files
.jpg   Clipboard01.jpg (Size: 33.45 KB / Downloads: 14,954)
Reply
#2
Can you zip and attach the code either to this thread or in a private message?
Reply
#3
Of course, here is.

Cheers


Attached Files
.zip   ocman_asm.zip (Size: 11 KB / Downloads: 697)
Reply
#4
oblo Wrote:Of course, here is.
Cheers
Your attachtment has a BOM (Byte Order Mark) for Unicode UTF-16, but appears to be encoded in an different encoding.
First two bytes of text are 0xFEFF which are cofusing the compiler. Also some chars are "dirty" or misencoded. Which encoding did you use?
Please use UTF-8 whenever possible. :!:

Update: your BOM is OK (UTF-8), but zxb does not understand BOMs (a 2-3 bytes at the beginning of the text file). Once removed I recompiled your program and got your error. The real error line is not at line 1917 but at 2662 (this is something I have to investigate further). Anyway, the syntax:
Code:
DEFB 5,0,5,0
DEFB 179,"cor","e"+$80
is not allowed. At the moment you cannot mix strings and bytes in the same DEFB line. I'm going to add this feature to the assembler.
Meanwhile you can workaround this rewriting the above line as:
Code:
DEFB 5,0,5,0
DEFB 179
DEFB "cor"
DEFB 'e'+$80
Note the last line: The assembler makes distinction between strings (double quotes " "), and char (single quotes ' '). A char is a byte written as an ASCII char, and can be added a number (+$80). A string cannot. So "e" + $80 is not legal, but 'e' + $80 is.
Reply
#5
Thanks for your quick response Smile I'll make those changes and will try. Besides, this is my first 'serious' ASM code, so it's possible that it contains errors Undecided

Cheers

Edit: after I made the changes, that error is solved but now I'm receiveing another one (Unexpected end of line [NEWLINE]) that is reported at <!-- l --><a class="postlink-local" href="http://www.boriel.com/forum/bug-reports/topic499.html">bug-reports/topic499.html</a><!-- l -->. Must I remove all blank lines?
Edit2: after close BorIDE and reload the project again, now I'm getting a different erro (12:48:34 -> temp.bor:1931: Error: Syntax error. Unexpected token '111' [INTEGER]. Compilation failed)
It seems the code need more debug than I thought at first Sad

Cheers
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)