roxen.lists.pike.general

Subject Author Date
interface dependence Ñ©ËÉ ¹ù <Ñ©ËÉ ¹ù[at]nirgendwo> 05-07-2009
Is there any method to make sure "anything inherit class A must inherit class B
too" at compiling time ?

for example:

class B{
    int property1;
}

class A{
#depend_on B
    void print_property1(){
        write("%d",this->property1);
    }
}


class ThingHasProperty1{
    inherit SomeBaseClass;
    inherit B;
}


class ThingHasProperty1Printable{

    inherit SomeBaseClass;

    inherit B;
    inherit A;

}



Class CompilingErrorShouldThrow{
    inherit SomeBaseClass;
    inherit A;
}

_________________________________________________________________
Invite your mail contacts to join your friends list with Windows Live Spaces.
It's easy!
http://spaces.live.com/spacesapi.aspx?wx_action=create&wx_url=/friends.aspx&mkt=en-us