Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:23120 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 18688 invoked by uid 1010); 3 May 2006 11:31:55 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 18672 invoked from network); 3 May 2006 11:31:55 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 3 May 2006 11:31:55 -0000 X-PHP-List-Original-Sender: derick@php.net X-Host-Fingerprint: 82.94.239.5 jdi.jdi-ict.nl Linux 2.5 (sometimes 2.4) (4) Received: from ([82.94.239.5:56071] helo=jdi.jdi-ict.nl) by pb1.pair.com (ecelerity 2.0 beta r(6323M)) with SMTP id 3A/18-63443-AA498544 for ; Wed, 03 May 2006 07:31:55 -0400 Received: from localhost (localhost [127.0.0.1]) by jdi.jdi-ict.nl (8.13.6/8.12.11) with ESMTP id k43BVpKJ019440; Wed, 3 May 2006 13:31:51 +0200 Date: Wed, 3 May 2006 13:29:54 +0200 (CEST) X-X-Sender: derick@localhost To: Marcus Boerger cc: php internals , Edin Kadribasic In-Reply-To: <6310340374.20060502222253@marcus-boerger.de> Message-ID: References: <444E0854.2000804@emini.dk> <200604251602.42837.bu@orbitel.bg> <444E2108.8050203@iamjochem.com> <749874265.20060426211537@marcus-boerger.de> <444FDF4C.4020303@emini.dk> <1421874376.20060427151948@marcus-boerger.de> <4450D6BB.2060007@emini.dk> <6310340374.20060502222253@marcus-boerger.de> X-Face: "L'&?Ah3MYF@FB4hU'XhNhLB]222(Lbr2Y@F:GE[OO;"F5p>qtFBl|yVVA&D{A(g3[C}mG:199P+5C'v.M/u@Z\![0b:Mv.[l6[uWl' MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Subject: Re: [PHP-DEV] Static properties From: derick@php.net (Derick Rethans) On Tue, 2 May 2006, Marcus Boerger wrote: > Edin and me discussed the issue a bit more in detail and shared memories > of discussions from the original php 5.0 development. As a conclusion we > came to the idea that we should revive the idea of a 'strict flag' that > decides whether member variables (both static and non static) can be added > on the fly by simply using them or not. This would for example look like > this: > > strict class FooBar > { > } > $obj = new FooBar; > $obj->baz = 1; // E_ERROR (a fatal non recoverable error level) > > class MyConfig > { > } > MyConfig::$allow_public_access = 1; // works pretty well > > Both of us thought this would be a great solution and should suit everybody > in the php world. Also the possible slowdown would be not measurable since > it is only a single integer check that in some cases won't have and > influence on runtime at all. > > Any thoughts? Anybody? I would like this too. Derick