flat assembler
Message board for the users of flat assembler.
 Home   FAQ   Search   Register 
 Profile   Log in to check your private messages   Log in 
flat assembler > Windows > Basic Win32 headers for fasmg

Author
Thread Post new topic Reply to topic
Tomasz Grysztar
Assembly Artist


Joined: 16 Jun 2003
Posts: 6179
Location: Kraków, Poland
Basic Win32 headers for fasmg
Recently I've been working on a set of basic compatibility macros for fasmg that would allow to assemble sources written for fasm with its standard Win32 headers, with as few changes as possible. I have now completed a version that assembles most of the Win32 examples from fasm package and I'm attaching it here.

Note that I do think that any such headers for fasmg (or fasm 2, if such ever arrives) could make better use of the macro capabilities of the new engine, therefore I think that developing some entirely new macros with new and improved syntax could be a good direction. But converting the standard fasm's includes is an important first step.

Not every behavior of fasm's macros is preserved - for example, as I explained in the other thread, "proc" macro I prepared for fasmg creates a separate namespace for every procedure - because this is how it should have always been working, and it was only because of the limitations of fasm's macro engine that its "proc" did not really work like that (though it at least kept the local data labels limited in scope). This means that local labels inside "proc" no longer need to start with dot.

The "struct" and "union" macros I used are the plain ones I created for fasmg, and they do not reproduce the complete behavior of fasm's "struct". This should change later - I still plan to write a variant more compatible with fasm's one for the inclusion in this package, though in general I prefer the new one, for its simplicity and flexibility. Using the new version required some changes of syntax in fasm's examples, because this variant of "union" needs to end with "endu" and the values to initialize fields in structure need to be labeled instead of providing them in original order.

When converting the resource macros I was really amazed how old and fossilized they are, with weird syntax choices that date back to the time when fasm had only very basic macro abilities, and implementations that have not been touched in ages. I converted them all, preserving the compatibility, but I think that their syntax really could use some renewal. The same can be said about import macros.


Description: Win32 headers for fasmg, with adapted fasm's examples
Download
Filename: fasmgwin32.zip
Filesize: 242.91 KB
Downloaded: 71 Time(s)



Last edited by Tomasz Grysztar on 30 Jan 2017, 10:30; edited 1 time in total
Post 17 Oct 2016, 22:47
View user's profile Send private message Visit poster's website Reply with quote
uor99



Joined: 04 Dec 2014
Posts: 39
Well done !
Post 24 Dec 2016, 12:41
View user's profile Send private message ICQ Number Reply with quote
uor99



Joined: 04 Dec 2014
Posts: 39
I also hope fasmg can replace fasm in time. It's a pity that some of my written apps fail to compile.
Post 10 Jan 2017, 21:55
View user's profile Send private message ICQ Number 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


Powered by phpBB © 2001-2005 phpBB Group.

Main index   Download   Documentation   Examples   Message board
Copyright © 2004-2016, Tomasz Grysztar.