
28 Sep
2005
28 Sep
'05
10:11 p.m.
"Reece Dunn" <msclrhd@hotmail.com> wrote in message news:BAY101-F67FCBC7D549563DC6FD47A08D0@phx.gbl...
What about:
static const unsigned char lookup_table[] = { ... };
The static tells the compiler that this is a global constant and not just related to this call of the function. The const tells the compiler that the data isn't (shouldn't be) modified.
I think this will work on all compilers. (Compare this with declaring class-based constants using "static const ...").
- Reece
Could you please elaborate this for a bit? What is the issue with using a const static member? Thanks, Sean