>
> The C language, in facts, does not even have CONSTs - it goes with 
> #define. So, it would be correct to forbid STATIC when declaring CONSTs.
Surely this is not correct. ANSI C uses const, and C++ also uses the 
const keyword.
#define (a preprocessor directive) is a relic from old C, and const is 
now recommended use instead.

Also, it would be correct to use static with const, the line below would 
be correct use.

static const int daysPerMonth[13] = {0,31,28,31,30,31,30,31,31,30,31,30,31};


Having said that, The original question was not about C,  I think Fabian 
was simply asking about the scope of constants in classes (in Gambas)


Regards
Les Hardy

------------------------------------------------------------------------------
Download Intel® Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user

Reply via email to