flat assembler
Message board for the users of flat assembler.
Index
> Macroinstructions > Ignored prevision macro, how do this ? |
Author |
|
revolution 03 Jun 2023, 11:10
Code: Ignor_flg equ 1 Put a if/end if inside the macro. |
|||
03 Jun 2023, 11:10 |
|
Roman 03 Jun 2023, 12:00
Quote:
Its work if I do first macroA set Ignor_flg equ 1 Than do second macroB check if Ignor_flg = 1 I want different way. Code: MacroB Some code MacroA |
|||
03 Jun 2023, 12:00 |
|
revolution 03 Jun 2023, 12:35
Use equ for preprocessor stage. Can't be forward referenced.
Use = for assembler stage. Can be forward referenced, but only for a single assignment. IF you have multiple assignments then you can't forward reference. |
|||
03 Jun 2023, 12:35 |
|
Roman 03 Jun 2023, 15:59
revolution wrote: Use equ for preprocessor stage. Can't be forward referenced. Hm. Did I can write my new pass(after preprocessor stage) in fasm source code ? And how hard implemented it to fasm ? |
|||
03 Jun 2023, 15:59 |
|
revolution 03 Jun 2023, 16:31
Use only a single assignment.
Code: ;Ignor_flg = 0 ; <--- don't put an assignment here! rept { ; <--- are you sure you want rept? "if" by itself should be fine. if ~ Ignor_flg ;... end if } ;... Ignor_flg = 1 ; <---use only one assignment ;Ignor_flg = 0 ; <--- don't put a second assignment here! |
|||
03 Jun 2023, 16:31 |
|
Roman 03 Jun 2023, 17:00
Code: macro mcAA p { if p = 1 Ignor_flg1 = p end if } if ~defined Ignor_flg1 inc ebp display 'uuu;;' end if ...some code mcAA 0 ;0=do inc ebp. 1=not do inc ebp |
|||
03 Jun 2023, 17:00 |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2024, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.