GLBasic forum

Main forum => Bug Reports => Topic started by: MrTAToad on 2009-Aug-25

Title: Variable problem
Post by: MrTAToad on 2009-Aug-25
With the following :

Code (glbasic) Select

FOR i%=STOREMESS% TO 0 STEP -1
NEXT


You get the usual two part error message :

QuoteC:\DOCUME~1\Nicholas\LOCALS~1\Temp\glbasic\gpc_temp0.cpp:16: error: `S' was not declared in this scope
C:\DOCUME~1\Nicholas\LOCALS~1\Temp\glbasic\gpc_temp0.cpp:16: error: `REMESS' was not declared in this scope
Title: Re: Variable problem
Post by: Quentin on 2009-Aug-25
funny, seems precompiler makes "S TO REMESS" of it
Title: Re: Variable problem
Post by: MikeHart on 2009-Aug-25
Is that an O or a zero inside STOREMESS?
Title: Re: Variable problem
Post by: MrTAToad on 2009-Aug-25
Its the letter O

A Zero looks like : 0

Quotefunny, seems precompiler makes "S TO REMESS" of it
Indeed it does - which it shouldn't :)
Title: Re: Variable problem
Post by: Kitty Hello on 2009-Aug-25
DO NOT USE CAPITAL WORDS PLEASE. THESE ARE FOR GLBASIC ONLY. KTHXBYE.
Title: Re: Variable problem
Post by: MrTAToad on 2009-Aug-25
Its something thats been mentioned before  =D
Title: Re: Variable problem
Post by: Moru on 2009-Aug-25
When I started with GLBasic you had to use all caps when declaring types. That isn't needed any more but I still do it out of habit...
Title: Re: Variable problem
Post by: Kitty Hello on 2009-Aug-26
No, it never was. It was a suggestion or .. I did. Now I changed to what Schranz0r Said:

TYPE TMyTypeName (Start with T, then Captial letter, then non capital letters)
Title: Re: Variable problem
Post by: Schranz0r on 2009-Aug-26
:)