rfc:void_return_type
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionNext revisionBoth sides next revision | ||
rfc:void_return_type [2015/10/14 21:46] – Link to pull request ajf | rfc:void_return_type [2015/10/29 01:20] – mention new keyword ajf | ||
---|---|---|---|
Line 1: | Line 1: | ||
====== PHP RFC: Void Return Type ====== | ====== PHP RFC: Void Return Type ====== | ||
- | * Version: 0.2 | + | * Version: 0.2.1 |
- | * Date: 2015-02-14 (v0.1), 2015-10-14 (v0.2, revival) | + | * Date: 2015-02-14 (v0.1, later withdrawn), 2015-10-14 (v0.2, revival) |
* Author: Andrea Faulds, ajf@ajf.me | * Author: Andrea Faulds, ajf@ajf.me | ||
- | * Status: | + | * Status: |
* First Published at: http:// | * First Published at: http:// | ||
Line 92: | Line 92: | ||
Moreover, IDEs and other tools can warn the user when the return value of a void function is being used. It isn't strictly necessary for the language itself to cover this. | Moreover, IDEs and other tools can warn the user when the return value of a void function is being used. It isn't strictly necessary for the language itself to cover this. | ||
+ | |||
+ | ==== Why call it void and not null? ==== | ||
+ | |||
+ | Some have suggested that the return type be named '' | ||
+ | |||
+ | The main reason to choose '' | ||
+ | |||
+ | The other reason is that '' | ||
===== Backward Incompatible Changes ===== | ===== Backward Incompatible Changes ===== | ||
Line 101: | Line 109: | ||
This is proposed for the next minor version of PHP, currently PHP 7.1. | This is proposed for the next minor version of PHP, currently PHP 7.1. | ||
- | ===== Proposed Voting Choices | + | ===== Vote ===== |
As this is a language change, a 2/3 majority is required. The vote is a straight Yes/No vote for accepting the RFC and merging the patch. | As this is a language change, a 2/3 majority is required. The vote is a straight Yes/No vote for accepting the RFC and merging the patch. | ||
+ | |||
+ | Voting started 2015-10-29 and ends < | ||
+ | |||
+ | <doodle title=" | ||
+ | * Yes | ||
+ | * No | ||
+ | </ | ||
===== Patches and Tests ===== | ===== Patches and Tests ===== | ||
Line 119: | Line 134: | ||
===== Changelog ===== | ===== Changelog ===== | ||
+ | * v0.2.1 - Add subsection explaining name choice | ||
* v0.2 - Revived, cleaned up proposal and rationale, added compile-time checking | * v0.2 - Revived, cleaned up proposal and rationale, added compile-time checking | ||
* v0.1.1 - Detailed implicit null return value | * v0.1.1 - Detailed implicit null return value | ||
* v0.1 - Initial version | * v0.1 - Initial version |
rfc/void_return_type.txt · Last modified: 2017/09/22 13:28 by 127.0.0.1