Qbasicnews.com
freeBASIC (a 32-bit QB-syntax compatible compiler) preview.. - Printable Version

+- Qbasicnews.com (http://qbasicnews.com/newforum)
+-- Forum: General (http://qbasicnews.com/newforum/forum-6.html)
+--- Forum: General/Misc (http://qbasicnews.com/newforum/forum-18.html)
+--- Thread: freeBASIC (a 32-bit QB-syntax compatible compiler) preview.. (/thread-4948.html)

Pages: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40


freeBASIC (a 32-bit QB-syntax compatible compiler) preview.. - ShadowWolf - 11-03-2004

jofers ya but what i have seen so far of the test there already a pretty larg lexcon for the lang and the systex look complete
and all the runtime's arn't need to compile the compiler.


freeBASIC (a 32-bit QB-syntax compatible compiler) preview.. - v3cz0r - 11-03-2004

There are many QB intrinsic functions/statements that the compiler uses and that aren't implemented yet like PRINT, SWAP, READ, RESTORE, OPEN and such, i'll probably have them implemented this week, so the first tries to compile itself will be done soon..

Today i added arrays on type fields, a VBDOS feature that the compiler uses a lot and that is also needed to access some structs from C APIs/libs.. you can do now such as: a(b).c.d(e,f).h = 1234, it was painful to code, i've to say.. ow


Byez.....


freeBASIC (a 32-bit QB-syntax compatible compiler) preview.. - barok - 11-03-2004

Quote:It's worth noting that Plasma is the one the that made Superput, from an assembly routine Rel modified for him from Rellib. He also made that routine floating around that changes the memory segment QB uses for its drawing routines from &HA000 to any specified address.

So sorry Plasma! :-?


freeBASIC (a 32-bit QB-syntax compatible compiler) preview.. - ShadowWolf - 11-03-2004

v3cz0r this compiler can use any C lib right what about somthing like Allgro ?


freeBASIC (a 32-bit QB-syntax compatible compiler) preview.. - adosorken - 11-03-2004

Bass.lib all the way. Big Grin Bass + OpenGL = all you ever need for game development.


freeBASIC (a 32-bit QB-syntax compatible compiler) preview.. - ShadowWolf - 11-03-2004

OpenGl na don't want to get into that just yet pluse i already understand allgro if i can get away with using that i will.


freeBASIC (a 32-bit QB-syntax compatible compiler) preview.. - adosorken - 11-03-2004

I would imagine it'd support Allegro if it can link any standard import library. Big Grin


freeBASIC (a 32-bit QB-syntax compatible compiler) preview.. - v3cz0r - 11-03-2004

You can use any non-OO library, being it static or dynamic (DLL), but for that the C header with function prototypes and other declarations first have to be ported/translated to FB's syntax, what isn't an easy task.

An automated tool is hard to make, due the way some C headers are written (loads of macros, typedefs and such), this has to be done by hand. Someone doing that must have full knowledge of C and VB/FB and a lot of patience.. if we have luck, we can just use headers/include-files already translated to be used with VB/PB, with some edition and search&replace, that wouldn't take more than a couple of minutes to be done (that was the case with the Opengl header).


freeBASIC (a 32-bit QB-syntax compatible compiler) preview.. - marzecTM - 11-03-2004

hey folks,

after finishing porting the sdl headers (well 85% of them) to fb i started writing a preprocessor for fb, since we all will need include guards at some stage (or coditional compiling). so here it is

http://ratatoskr.bad-logic.com/temp/pp.zip

it offers the following stuff:

* include: 'FILENAME'
* define SYMBOL
* ifdef / ifndef SYMBOL
* else
* endif

where SYMBOL is just a NAME like SDL_BI or something. anybody that knows the c/c++ preprocessor will feel at home. ifdef/ifndefs can be nested as much as you want. some restrictions:

SYMBOL can only be a single word, you can't give a SYMBOL a value (like for constants) use const instead.

hm can't think of any other restrictions at this point.

here's an example for an include guard

Code:
'$ifndef INCFILENAME_H_
'$define INCFILENAME_H_

do some declarations here ....

'$endif

well feel free to find other uses for the preprocessor. if anybody needs some additions to that just tell me, i'll see what i can do...

marzec


freeBASIC (a 32-bit QB-syntax compatible compiler) preview.. - adosorken - 11-04-2004

Y'all realize that this is the future of QB, right? Big Grin

You got my support. Smile I hope more people see this and encourage its development and completion, then we can put the old MSDOS-based workhorse to rest at long last and be competative in the "real world" again. Big Grin