roxen.lists.pike.general

Subject Author Date
Martin Stjernholm <mast[at]lysator[dot]liu[dot]se> 11-10-2009
 mapping
郭雪松 <<peterpan[at]wukong.com>> wrote:

> Because class A is a single file A.pike, and C2 belong to A, take C2
> out and add a file C2.pike is boring.

Understandable, but adding a keyword to control an aspect of an
implementation detail is quite boring too. This is what a real
"static" property should do.

In the meantime, there are ways to work around it. Another option
could be to have a module.pmod top level instead and put both the
inner classes and the outer class there. Then at least they are in the
same file. They might not be constant in the sense that they'll lack
parent pointers, but they will be just as much singletons as other
constants.