Re: C# properties vs. accessors RFC

From: Date: Wed, 23 Jan 2013 23:45:34 +0000
Subject: Re: C# properties vs. accessors RFC
References: 1 2 3 4 5 6 7  Groups: php.internals 
Request: Send a blank email to [email protected] to get a copy of this message
On 1/23/2013 5:04 PM, Crypto Compress wrote:
guard->in_unset = 1; /* Prevent recursion */ zend_call_method_with_1_params(&object, zobj->ce, &zobj->ce->__unset, ZEND_UNSET_FUNC_NAME, NULL, member); guard->in_unset = 0; /* Prevent recursion */ a) That applies to __unset (magic method) only
b) guard is name specific (another name would have a different guard) c) Those three lines are not new code, they have just been moved around a bit. The code (for unset accessors) you are looking for is here: https://github.com/cpriest/php-src/blob/accessors-5.5/Zend/zend_object_handlers.c#L986
this code would only prevent nested/parallel access to same accessor but not circular? e.g.: getter -> setter -> null-checker -> null-setter -> getter sorry it this is a dumb question :) cryptocompress
-- -Clint

Thread (19 messages)

« previous php.internals (#65136) next »