

EDIT: Is it case sensitive?
Cheers,
-naota
Instructions are case insensitive, and symbols are case sensitive (like HyASM).AaronMiller wrote: EDIT: Is it case sensitive?
Code: Select all
Hello: db "Hello, world!", 13, 10
Length equ $ - Hello
Code: Select all
Error: console.asm(55): invalid instruction or directive ("Hello").
HyASM doesn't support yet the '$' operator. I don't like the "name" : $. I should find a name more understandable,Hobbes wrote: In the console example I tried to automatically calculate the length of the string:This caused the following error:Code: Select all
Hello: db "Hello, world!", 13, 10 Length equ $ - Hello
Is this something still to be implemented?Code: Select all
Error: console.asm(55): invalid instruction or directive ("Hello").
The RELATIVE operator is equivalent to the RVA operator in FASM. It get the relative address of a symbol to the base addressHobbes wrote: Nice start with the manual. I think it's complete enough for people already familiar with assembly language. I'm not sure if I understand the RELATIVE operator though, and should OFFSET really be relative to some section?
This differs a lot from the OFFSET operator in MASM and TASM syntax, doesn't it? I mean, the next two are equivalent in MASM but not in HyASM:Tommy wrote:OFFSET contains the current offset in the section. To be clear: OFFSET = $ - SECTADDR.
Code: Select all
push dword Hello
push offset Hello
In MASM/TASM, the OFFSET operator is used to get the address of a symbol. This is very different.Hobbes wrote: This differs a lot from the OFFSET operator in MASM and TASM syntax, doesn't it? I mean, the next two are equivalent in MASM but not in HyASM:(Not that MASM accepts "dword <symbol>" but you get the idea.)Code: Select all
push dword Hello push offset Hello
Perhaps I will merge this project to HyASM to provide a new high-level assembler syntax...Tommy wrote: Perhaps I will begin my other project of a new programming language...
Then I think you shouldn't call it OFFSET. It's confusing. How about INSECT?Tommy wrote:In MASM/TASM, the OFFSET operator is used to get the address of a symbol. This is very different.
INSECT?Hobbes wrote:Then I think you shouldn't call it OFFSET. It's confusing. How about INSECT?Tommy wrote:In MASM/TASM, the OFFSET operator is used to get the address of a symbol. This is very different.
OK. Will be changed for version 0.3.0.AaronMiller wrote:I like $OFFSET.