Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:12172 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 89940 invoked by uid 1010); 15 Aug 2004 15:09:06 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 89827 invoked from network); 15 Aug 2004 15:09:05 -0000 Received: from unknown (HELO iko.gotobg.net) (80.168.8.116) by pb1.pair.com with SMTP; 15 Aug 2004 15:09:05 -0000 Received: from pd95e9af1.dip.t-dialin.net ([217.94.154.241] helo=[192.168.0.32]) by iko.gotobg.net with asmtp (Exim 4.34) id 1BwMdA-0003hV-B1 for internals@lists.php.net; Sun, 15 Aug 2004 18:09:08 +0300 Message-ID: <411F9833.6030007@php.net> Date: Sun, 15 Aug 2004 17:06:59 +0000 User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8a2) Gecko/20040627 X-Accept-Language: en-us, en MIME-Version: 1.0 To: internals@lists.php.net Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - iko.gotobg.net X-AntiAbuse: Original Domain - lists.php.net X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - php.net X-Source: X-Source-Args: X-Source-Dir: Subject: Checking whether parameter is passed by ref From: andrey@php.net (Andrey Hristov) Hello, the topic clearly states what I would like to achieve. I know that parameter can be forced to be passed by reference when declared but in my case this is not an option (still). I would like to determine this at run time based on some other conditions I have to check whether the param is a reference or not (whether variable was passed or value (like "foo")). I have found some documentation and examples that use ParameterPassedByReference() function of ZE1. However Zeev has removed it from the engine at Jul 30, 2001 (commit msg : "More TSRMLS_FETCH work, and get rid of redundant ParametersPassedByRef"). I have tried with PZVAL_IS_REF(*str) (zval **str), but no success - (*str)->is_ref is 0. The old parameters parsing API is used : zend_get_parameters_ex() I even tried to copy the removed function and it still does not give me the wanted result In brief I want the the example to find out that the second call used a variable. Thanks in advance, Andrey