rfc:true-nested-function-support

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Last revisionBoth sides next revision
rfc:true-nested-function-support [2011/07/18 12:29] runerfc:true-nested-function-support [2013/02/21 03:04] tyrael
Line 1: Line 1:
-====== Request for Comments: How to write RFCs ======+====== Request for Comments: True nested function support ======
   * Version: 1.0   * Version: 1.0
   * Date: 2011-06-18   * Date: 2011-06-18
Line 15: Line 15:
 ===== Code examples ===== ===== Code examples =====
  
-====== 1) Appending the function name and wrapping in function_exists() ======+====== 1) Current idiomatic usage of helper functions ====== 
 +<code php> 
 +    function _prefix_functionname_helperfunctionname($arg1, $arg2) { 
 +        ; 
 +    } 
 +            
 +    function prefix_functionname() { 
 +       // Code here... 
 +       somefunc(prefix_functionname_helperfunctionname($arg1, $arg2)); 
 +    } 
 +</code> 
 + 
 +====== 2) Appending the function name and wrapping in function_exists() ======
 <code php> <code php>
     function prefix_functionname() {     function prefix_functionname() {
Line 28: Line 40:
 </code> </code>
  
-====== 2) Using closures ======+====== 3) Using closures ======
 <code php> <code php>
     function prefix_functionname() {     function prefix_functionname() {
Line 39: Line 51:
 </code> </code>
  
-====== 3) Using new syntax ======+====== 4) Using new syntax ======
 <code php> <code php>
     function prefix_functionname() {     function prefix_functionname() {
Line 51: Line 63:
  
 ===== Todo for this RFC ===== ===== Todo for this RFC =====
-  * Write little script that checks for use of internal functions in common frameworks like Symphony and Zend.+  * Write little script that checks for the current use of nested functions in common frameworks like Symphony and Zend. I am assuming this is zero.
  
rfc/true-nested-function-support.txt · Last modified: 2017/09/22 13:28 by 127.0.0.1