Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:11907 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 85290 invoked by uid 1010); 4 Aug 2004 12:56:56 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 85266 invoked by uid 1007); 4 Aug 2004 12:56:56 -0000 Message-ID: <20040804125656.85265.qmail@pb1.pair.com> To: internals@lists.php.net Reply-To: "l0t3k" References: <131164997375.20040804100719@vrana.cz> <183170577390.20040804114019@vrana.cz> Date: Wed, 4 Aug 2004 08:56:01 -0400 Lines: 23 X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2800.1106 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1106 X-Posted-By: 65.3.13.187 Subject: Re: [PHP-DEV] Document call_time_pass_reference From: cshmoove@bellsouth.net ("l0t3k") "Jakub Vrana" wrote in message news:183170577390.20040804114019@vrana.cz... >>This is what I need to know :-). In php.ini-recommended there is only >>[Code cleanliness] reason. in other (compiled) programming languages, a function prototype specifies the "contract" between the function and its callers, and makes explicit the programmer's intentions as to how the function is to be called. Usually expected parameter types and passing methods specified by the function as checked at compile-time to ensure that parameters passed to the function are as expected. in specifying a parameter as by-reference, the programmer makes it clear that the function may modify the value of the parameter. In specifying the parameter as by-value, s/he states that the passed in parameter will not reflect any changes when the function returns. This is its "contract" with the caller of the function. However, allowing call_time_pass_reference violates this by bypassing the programmer's explicit intention in not declaring a parameter by reference. l0t3k