Search found 27 matches

by toml_12953
Jun 17, 2006 1:40
Forum: General
Topic: Variable Scope within Compund Statements - Why?
Replies: 53
Views: 8696

v1ctor wrote:Alright, end of discussion, see the CVS (http://cia.navi.cx/stats/project/fbc). Enjoy.

Somebody will have to document the scope rules now..


Thank you! If I didn't like FB, I wouldn't have spent so much time replying to everyone. I think you made a good decision.

Tom Lake
by toml_12953
Jun 17, 2006 1:28
Forum: General
Topic: Bug
Replies: 13
Views: 2689

A bug in your code. dim a as integer do a = a + 1 print a gosub 20 loop until a = 10 sleep 20 print a*2 return Compiled with –exx: Aborting due to runtime error 12 ("segmentation violation" signal) in junk1.bas: :() An end statement after sleep will fix the problem. Your c...
by toml_12953
Jun 17, 2006 1:26
Forum: General
Topic: Variable Scope within Compund Statements - Why?
Replies: 53
Views: 8696

Seriously, the BASIC community is "growing up", and maybe you wanna stay on neverland ranch for the rest of your life, but I prefer the power that age and wisdom brings =) jevans: He already said it's technical. :P But there are Windows compilers which don't behave this way so the technical limitat...
by toml_12953
Jun 16, 2006 22:20
Forum: General
Topic: Variable Scope within Compund Statements - Why?
Replies: 53
Views: 8696

I mean we are not paying v1ctor to make and update FB, he does it because he loves the BASIC language. And I don't think anybody here would argue with me that BASIC as a language should "evolve" to be useful in the 21st century. And yes, line numbers are still supported. :*) He loves HIS idea of th...
by toml_12953
Jun 16, 2006 22:08
Forum: General
Topic: Bug
Replies: 13
Views: 2689

Bug

The following code causes an error in XP rather than handling the error within FB. The error is, of course caused by "falling into" the subroutine at line 20.

do
a = a + 1
print a
gosub 20
loop until a = 10
sleep

20 print a*2
return
by toml_12953
Jun 16, 2006 21:55
Forum: General
Topic: Variable Scope within Compund Statements - Why?
Replies: 53
Views: 8696

If a person wants to program in old-style basic, you can still "not" DIM variables and use all of the GOTO commands you need. If a person wants to use modern conveniences such as subroutines and functions and 32bit windows and the like, then maybe they should also step into a more structured type o...
by toml_12953
Jun 16, 2006 21:51
Forum: General
Topic: Variable Scope within Compund Statements - Why?
Replies: 53
Views: 8696

And you didn't complain when MS made BASIC support subs? With this add-ons and changes, I still believe FB is BASIC. Not your usual BASIC but BASIC with style. :*) Yes, MS made BASIC support SUBS, but NOT at the cost of backward compatibility. You can still use spaghetti code in QBasic, Quick BASIC...
by toml_12953
Jun 16, 2006 21:48
Forum: General
Topic: Variable Scope within Compund Statements - Why?
Replies: 53
Views: 8696

BASIC Was never meant to teach, it was meant to make things easy so anyone could pick it up and make something (anyone ;-) ). That's exactly wrong! Kemeny and Kurtz at Dartmouth created BASIC just for that purpose. To teach their students how to program and make it easy for beginners. That's why fo...
by toml_12953
Jun 16, 2006 18:43
Forum: General
Topic: is this where i post problem's with fbc....
Replies: 36
Views: 5106

Bad Code

Wow, now I know why C people hate BASIC, and I almost agree with them... sorry if I sound insulting, but that kind of code shouldn't be supported, it's just not understandable. If you're writing code that looks like that, you're not going to get anywhere with it anyway, sorry, but you'd be better o...
by toml_12953
Jun 16, 2006 17:41
Forum: General
Topic: is this where i post problem's with fbc....
Replies: 36
Views: 5106

FreeBASIC had some pretty important changes from .15->.16. For example: do a = a + 1 loop until a = 10 ? a if you don't use Option Explicit, that code prints out "0", not 10 like it used to. Option Explicit throws a compile-stopping error, so you know what needs to be done. It's because inside of i...
by toml_12953
Dec 05, 2005 3:38
Forum: General
Topic: DEFxxx statments with single variable
Replies: 3
Views: 852

DEFxxx statments with single variable

In other BASICs that support DEFINT, DEFSNG, DEFDBL or DEFSTR statements the following works:

DEFDBL a

All variable that start with the letter a will be double.

FreeBASIC gives an error that '-' is needed.

DEFDBL a-a works but seems silly.
by toml_12953
Dec 02, 2005 4:46
Forum: Beginners
Topic: Compiling FB
Replies: 3
Views: 879

Compiling FB

Are there instructions somewhere for compiling the FB source? What module id compiled first? I try to compile fbc.bas and get the error: inc\fb.bi(199) : error: Unsupported target.

I'm compiling on WinXP Pro.

TIA

Tom Lake

Go to advanced search