flat assembler
Message board for the users of flat assembler.

Index > Macroinstructions > How I can defina a variable from macros?

Author
Thread Post new topic Reply to topic
dead_body



Joined: 21 Sep 2005
Posts: 187
Location: Ukraine,Kharkov
dead_body
Good Day! Today I have another question.(Subj)
Code:
format PE GUI 4.0
include "C:\fasm\INCLUDE\WIN32AX.INC"
macro create_var size,name
{
 ???
}
.data

.code
EntryPoint:
    create_var SizeOfVar,NameOfVar
    
    ret
.end EntryPoint
    


what I must use in create_var macro to define the var in section data?
I can't use ".data" like in masm, because fasm creates a new section data.
Post 23 Feb 2006, 13:04
View user's profile Send private message Reply with quote
decard



Joined: 11 Sep 2003
Posts: 1092
Location: Poland
decard
take a look at iglobal/uglobal macros from Fresh package (include\macro\globals.inc\)
Post 23 Feb 2006, 13:28
View user's profile Send private message Visit poster's website Reply with quote
vid
Verbosity in development


Joined: 05 Sep 2003
Posts: 7105
Location: Slovakia
vid
hey decard, still not using "idata" / "udata"?

dead_body: rather download FASMLIB (it's in projects section) and look into file "module\fasmlib.inc" at declaration of "idata" , "udata", "IncludeIData", "IncludeUData". You got it commented there.

But it's kinda complicated if you are a newbie
Post 23 Feb 2006, 13:36
View user's profile Send private message Visit poster's website AIM Address MSN Messenger ICQ Number Reply with quote
decard



Joined: 11 Sep 2003
Posts: 1092
Location: Poland
decard
Smile don't worry, I will change it sooner or later.
Post 23 Feb 2006, 14:00
View user's profile Send private message Visit poster's website Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  


< Last Thread | Next Thread >
Forum Rules:
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Copyright © 1999-2020, Tomasz Grysztar. Also on GitHub, YouTube, Twitter.

Website powered by rwasa.