Re: [PHP4BETA] cvs: /php4 php.h /php4/ext/standard file.c
| From: | Andi Gutmans | Date: | Mon, 01 May 2000 04:10:18 +0000 |
| Subject: | Re: [PHP4BETA] cvs: /php4 php.h /php4/ext/standard file.c | ||
| References: | 1 | Groups: | php.version4 |
| Request: | Send a blank email to php-version4+get-14245@lists.php.net to get a copy of this message | ||
At 09:32 PM 4/30/00 -0400, Sterling Hughes wrote:
Andi Gutmans wrote:I have no idea how Perl does it, we just created these macro's because it started to be annoying to write (*foo)->value.str.val (Z_STRVAL_PP(foo)), foo->value.lval (Z_LVAL_P(foo)) and so on. I personally think they are quite nice and readable. Andi --- Andi Gutmans <andi@zend.com> http://www.zend.com/andi Sun Apr 30 09:32:37 2000 EDTModified files:/php4 php.h /php4/ext/standard file.cLog: - Take Sascha's advice and create on V_OPEN() which replaces open(). - Unlike the other macros its argument has to have braces around it, for - example, open(filename, flags) becomse V_OPEN((filename, flags)) - Made small conversion to new Zend macros. The ugly (*foo)->value.str.val - now becomes Z_STRVAL_PP(foo). PP means pointer pointer, there also exist - single P's for example foo->value.str.val becomes Z_STRVAL_P(foo). Is this the start of the Perlifying the internals: SvPv(foo) -- Perl Z_STRVAL_PP(foo) -- Zend