Re: parent_ctor()

From: Date: Tue, 18 Jul 2000 12:12:53 +0000
Subject: Re: parent_ctor()
References: 1  Groups: php.dev 
Request: Send a blank email to php-dev+get-24892@lists.php.net to get a copy of this message
David Hjortso wrote: > Private functions and variables. If you do this, people will cry for functionality to access things marked private despite the fact that these are marked private within 10 seconds of deployment of this feature. I don't speak C++ fluently, but isn't this what "friends" do in C++? The first question I ask: Is "private" functionality worthwhile? Which problem exactly are you trying to solve with "private" instance variables and instance methods? And what shall the semantics of "private" exactly be? - Shall it generate an error and halt the interpreter if you are trying to access a private variable or method? You'll most definitely "friends" then. - Shall it generate a suppressable warning instead, but execute the access normally (would make implementing a "friends mechanism" obsolete)? - Or shall "private" be a second namespace within an object which can only be accessed from the inside, so that you can have a $this->myvar and a private $this->myvar at the same time? This will open a really large can of worms. Kristian -- Kristian Köhntopp, NetUSE AG Siemenswall, D-24107 Kiel Tel: +49 431 386 436 00, Fax: +49 431 386 435 99 Using PHP3? See our web development library at http://phplib.netuse.de/

« previous php.dev (#24892) next »