Hi!

> I apologize for my confusing terminology - let me elaborate. There are
> no special syntaxes. The below code should help clear things up a bit:
> 
>     class MyClass {
>       private $otherProperty;
>       public $property {
>         get() {}; // Does not "have a body", as there is no code between
>     the curly braces.

It does have a body. This body is just default empty method body
returning null - which does not throw any exceptions and is completely
indistinguishable from the outside from property being equal to null.
I'm not sure it's what the intent of *-only variable is, though I guess
it is a way to hack around it. I wonder however if it can be done better.

-- 
Stanislav Malyshev, Software Architect
SugarCRM: http://www.sugarcrm.com/
(408)454-6900 ext. 227

-- 
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to