Search found 298 matches

by TeeEmCee
Sep 08, 2009 5:34
Forum: Community Discussion
Topic: FreeBASIC for commercial projects?
Replies: 14
Views: 2217

Version numbers should never be trusted! Much more informative is the number of releases and length of development. Gmail was still Beta until recently. FB definitely was not stable three years ago and was a quickly moving target, but it seems to have finally slowed down since the 0.18.x series. I t...
by TeeEmCee
Sep 08, 2009 5:28
Forum: Community Discussion
Topic: The ugliest macro you've ever seen
Replies: 9
Views: 1644

Macros have other uses besides as shortcuts. You can also use them to hide implementation details, which can help a lot for making code more readable.
by TeeEmCee
Sep 08, 2009 5:04
Forum: Tips and Tricks
Topic: Attempt at implementing inheritance in FreeBASIC
Replies: 22
Views: 4853

Has the syntax/semantics of inheritance been planned? Any discussions about it anywhere? That would be the place to start.
by TeeEmCee
Apr 28, 2009 14:53
Forum: General
Topic: Redim Bug!?
Replies: 13
Views: 2049

I like to think of this as a bug in FB's type checking. It should really throw a run- or compile-time error. It's been a while since I studied FB's array code and assembly generation in detail and wrapped this added type checking around the RTlib, but I think there was a simple hack to determine whe...
by TeeEmCee
Sep 26, 2007 13:58
Forum: General
Topic: Global variable types not exported
Replies: 0
Views: 956

Global variable types not exported

Global variables which are arrays don't seem to have their types exported in the symbol table. For example (at top of main module): DIM plotstr(15) as Plotstring (gdb) ptype PLOTSTR type = <unknown type> (gdb) p PLOTSTR $3 = <error type> I can get around this by writing: (gdb) p (PLOTSTRING[16]) **(...
by TeeEmCee
Sep 04, 2007 15:10
Forum: General
Topic: In which direction do you want for FreeBASIC to develop?
Replies: 44
Views: 9954

GCC as backend is my most desired feature - even over OOP - because of compiling for Macs and GP2X handhelds and similar. Even if the fbgfx library, or OS functions like threads and mutexs can't be guaranteed on other platforms, that wouldn't trouble me at all: just use SDL! I agree with anonymous13...
by TeeEmCee
Aug 24, 2007 12:36
Forum: General
Topic: Preprocessor depths
Replies: 7
Views: 1707

So, imagine your code with the macro being replaced with what it would expand to. That should help you understand why there might be scope issues or some such. Although, I'm not really sure about a lot of it :-) I don't follow. C:/FreeBASIC/FBIDETEMP.bas(2) error 77: Recursive DEFINE not allowed, f...
by TeeEmCee
Aug 21, 2007 13:49
Forum: General
Topic: Preprocessor depths
Replies: 7
Views: 1707

Preprocessor depths

A search of the forums and of the manual produces very little information about the preprocessor, so I'm asking here. The FB preprocessor understands the scope of the actual code. That's great, but how do you define a macro or #define rule inside a block of code so that it is defined globally? defin...
by TeeEmCee
Aug 03, 2006 5:56
Forum: Tips and Tricks
Topic: GOSUB in SUB
Replies: 7
Views: 4036

Hmm. Here's what I used: #include "crt.bi" '#include "crt/setjmp.bi" ' setjmp.bi is incorrect type crt_jmp_buf:dummy(63) as byte:end type #ifdef __FB_WIN32__ declare function setjmp cdecl alias "_setjmp" (byval as any ptr) as integer #else declare functi...
by TeeEmCee
Jul 24, 2006 12:14
Forum: Tips and Tricks
Topic: (FBMLD) FreeBASIC Memory Leak Detector
Replies: 51
Views: 22136

Re: (FBMLD) FreeBASIC Memory Leak Detector

Ah, the uses of preprocessor redefines... Note: You must use parentheses in allocate/callocate/reallocate/deallocate calls when using FBMLD. For example, this won't work: deallocate p Instead, write this: deallocate(p) *plugplug* Since FB has argument lists without parenthesises, wouldn't it...
by TeeEmCee
Jul 23, 2006 5:21
Forum: General
Topic: The wiki lies/FB 0.16b broke my code
Replies: 11
Views: 2065

Extern? Hmm.. these aspects of QB/FB still remain arcane to me... as I understand, common shared declares extra modular global variables, requiring a seperate dimming of arrays, whereas extern functions like you would expect straight forward C-like globals to. In that case, I see why extern is (righ...
by TeeEmCee
Jul 22, 2006 8:51
Forum: General
Topic: The wiki lies/FB 0.16b broke my code
Replies: 11
Views: 2065

Comeon SURELY such a bug would break 90% of programs. Is there anyone out there actually using 0.16b, or is everyone using the 0.17b WIP??
by TeeEmCee
Jul 22, 2006 3:52
Forum: General
Topic: The wiki lies/FB 0.16b broke my code
Replies: 11
Views: 2065

The wiki lies/FB 0.16b broke my code

I'll stick this in the newbie questions forum since it deals with some pretty basic stuff. I've been porting some FB code that ran fine with 0.15b to work with 0.16b (cleaning up gosubs and retranslated headers and all that). Was I ever shocked to discover that I can no longer share arrays between m...

Go to advanced search