flat assembler
Message board for the users of flat assembler.
Index
> Macroinstructions > Extending proc macro with "public" |
Author |
|
revolution 31 May 2010, 17:16
Extending proc to do that would be quite easy. In much the same way that stdcall and c are detected you can add public.
But, of course, it would only work with linkable output formats. |
|||
31 May 2010, 17:16 |
|
Tyler 31 May 2010, 20:48
Is there a way to tell what format is being used, like an internal variable or something? Kinda like % can be used to get the number of the current iteration of a "repeat."
|
|||
31 May 2010, 20:48 |
|
baldr 31 May 2010, 21:10
Tyler,
No, AFAIK. In most cases one can check for low $$ symbol value to detect COFF, but this is unreliable. (?) |
|||
31 May 2010, 21:10 |
|
alorent 01 Jun 2010, 08:59
Thanks revolution.
I have been trying to extend the proc macro but cannot get it to work Well, with my lack of knowledge in macros... I mean, I want that the "public" word can be added or not and not just make all procs public. Any help? |
|||
01 Jun 2010, 08:59 |
|
revolution 01 Jun 2010, 09:10
You can try to add this to PROC32.INC:
Code: ... match =params, params \{ params equ statement flag = 0 \} ; ADD vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv match =PUBLIC args, params \{ params equ args public name \} match =PUBLIC, params \{ params equ public name \} ; ADD ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ match =uses reglist=,args, params \{ regs equ reglist params equ args \} ... |
|||
01 Jun 2010, 09:10 |
|
alorent 01 Jun 2010, 12:08
Thanks revolution!
I have checked it but unfortunately, the proc is not made public. The "PUBLIC" after proc is accepted by the assembler with your modifications, but the "public name" directive does not seem to make effect. Code: TestProc proc PUBLIC param1 fffffff ; this should produce error ret TestProc endp The above is compiled correctly. Only when I put explicitly "public TestProc" the assembler gives error on "ffffffff" line. Thanks |
|||
01 Jun 2010, 12:08 |
|
revolution 01 Jun 2010, 12:17
alorent wrote:
Code: proc TestProc PUBLIC param1 |
|||
01 Jun 2010, 12:17 |
|
baldr 01 Jun 2010, 12:34
alorent wrote: Only when I put explicitly "public TestProc" the assembler gives error on "ffffffff" line. |
|||
01 Jun 2010, 12:34 |
|
alorent 02 Jun 2010, 09:22
Thanks a lot guys!
|
|||
02 Jun 2010, 09:22 |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2025, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.