flat assembler
Message board for the users of flat assembler.
![]() |
Author |
|
revolution
Use the hash:
Code: mov ax,[tst#.wDay] |
|||
![]() |
|
jumpex
Yes. That worked. #
Now why didn't I find that anywhere? If you don't have a source where I can read about it (which I am sure you will, but) - how does it work? |
|||
![]() |
|
revolution
Inside macroinstruction also special operator # can be used. This operator causes two names to be concatenated into one name. It can be useful, because it's done after the arguments and local names are replaced with their values. |
|||
![]() |
|
jumpex
Now I remember.
Thank you. |
|||
![]() |
|
jumpex
It's offtopic, but it's too small of a question to start a new thread about.
Code: [...] lamb rb 128 [...] ;do something with lamb mov dword[lamb],0 [...] I want to "clear" [lamb], as I append strings to it. Is this a correct way to do so? If not - what is the correct way? Again - sorry for the offtopic. |
|||
![]() |
|
revolution
Do you want to clear (set to zero) the entire 128 bytes? Are you using null terminated strings?
|
|||
![]() |
|
jumpex
Yes. Yes.
|
|||
![]() |
|
revolution
Since you are using null terminated strings then this will suffice:
Code: mov [lamb],0 |
|||
![]() |
|
jumpex
Thanks.
You've been very helpful. |
|||
![]() |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2020, Tomasz Grysztar. Also on GitHub, YouTube, Twitter.
Website powered by rwasa.