Hello Aare!
Replying to a message of Aare Tali to Thomas Maeder:
>> As I said before, I don't understand you. For
>> ordinary functions and
>> variables, 'static' has to have the same effect in C++
>> as in C.
AT> I'm talking about methods. I tried this on some compilers long time
AT> ago, and it failed.
AT> class x {
AT> private:
AT> void xx(void);
AT> };
AT> static void x::xx(void)
AT> {
AT> }
this is not a valid c++ declaration or definition.
you can't change the storage class at the definitionlevel
declare:
class x{
static void xx();
}
define:
void x::xx(){}
AT> BC++ 3.1 complained that multiple storage classes specified. OK,
AT> first one is static. But what is second? 'Method that has to be
AT> visible to other modules even if it is private and is used only in
AT> this module, with the compiler being responsible for preventing
AT> others to access it'? Impressive.
this does not make sense to me at all.
To me you are the victime of serious mistakes and misunderstandings.
the above (correct) definition and declaration does exactly what it is
meant to do.
0 Erik!
|-
|\
--- FleetStreet 1.18 NR
---------------
* Origin: DataVisor BBS - TeamOS2 (2:238/52.136)
|