Could someone please tell me wat the equivilent of assume is in fasm?
Posted on 2003-01-12 14:08:46 by keyoke
It depends on what kind of assume you need. If you mean the one for structures, you can use such macro:


macro assume reg,struc
{ local _reg
reg equ _reg
reg struc
restore reg }

and use it like this:


assume eax,RECT
mov [eax.left],4

But IMO it's better to just use "mov ,4" instruction, it causes less problems.
Posted on 2003-01-12 15:17:42 by Tomasz Grysztar
ya this is wat i was looking at mostly for structured exception handling, and also for MZ/PE/OP headers

eg.
masm32
assume edi:ptr IMAGE_DOS_HEADER
or
assume edx:ptr SEH

now i will be able to implement these in my code properly
thanks
Posted on 2003-01-13 15:16:20 by keyoke
I'm sorry, it had to be:


macro assume reg,struc
{ local _reg
virtual at reg
reg equ _reg
reg struc
end virtual
restore reg }

But I recommend the other way of doing that:


virtual at eax
arc RECT ; name it as you wish
end virtual
mov [arc.left],4 ; will become mov [eax+0],4
Posted on 2003-01-13 17:56:54 by Tomasz Grysztar
oh ok thnx for the help:-)
Posted on 2003-01-13 18:01:40 by keyoke