rfc:compact

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:compact [2018/05/25 02:19] – Fix ordering of the sections carusogabrielrfc:compact [2018/06/18 23:22] – The RFC was accepted carusogabriel
Line 3: Line 3:
   * Date: 2018-05-24   * Date: 2018-05-24
   * Author: Gabriel Caruso (<carusogabriel34@gmail.com>)   * Author: Gabriel Caruso (<carusogabriel34@gmail.com>)
-  * Status: Under Discussion+  * Status: Accepted
   * First Published at: https://wiki.php.net/rfc/compact   * First Published at: https://wiki.php.net/rfc/compact
  
Line 12: Line 12:
 ===== Proposal ===== ===== Proposal =====
  
-This RFC proposes the addition of a warning in the //compact()// function when a not defined variable had been passed to it.+This RFC proposes the addition of a notice in the //compact()// function when a not defined variable had been passed to it.
  
 <code php> <code php>
 $foo = 'bar'; $foo = 'bar';
  
-$baz = compact('foz'); // Warning: compact(): Undefined variable: foz+$baz = compact('foz'); // Notice: compact(): Undefined variable: foz
 </code> </code>
      
 ===== Backward Incompatible Changes ===== ===== Backward Incompatible Changes =====
  
-Undefined variables passed to //compact()// will now be reported as a warning.+Undefined variables passed to //compact()// will now be reported as a notice.
  
 ===== Proposed PHP Version ===== ===== Proposed PHP Version =====
Line 35: Line 35:
  
 Since this RFC contains a Backward Incompatible Change, 2/3 majority is required. Since this RFC contains a Backward Incompatible Change, 2/3 majority is required.
 +
 +<doodle title="Make compact function reports undefined passed variables" auth="carusogabriel" voteType="single" closed="true">
 +   * Yes
 +   * No
 +</doodle>
 +
 +Voting starts on 2018-06-06 and ends on 2018-06-18 23:00 UTC.
  
 ===== Proposal and Patch ===== ===== Proposal and Patch =====
rfc/compact.txt · Last modified: 2018/06/19 10:52 by cmb