This is an old revision of the document!
PHP RFC: Your Title Here
- Version: 0.9
- Date: 2021-03-20
- Author: Max Semenik, maxsem.wiki@gmail.com
- Status: Draft
- First Published at: http://wiki.php.net/rfc/iterator_chaining
Introduction
The elevator pitch for the RFC. The first paragraph of this section will be slightly larger to give it emphasis; please write a good introduction.
Proposal
trait IteratorChain { public function skip(int $count): LimitIterator {} public function regexFilter(string $regex, int $mode = RegexIterator::MATCH, int $flags = 0 , int $preg_flags = 0): RegexIterator {} public function callbackFilter(callable $callback): CallbackIterator {} public function noRewind(): NoRewindIterator {} public function cached(int $flags = CachingIterator::CALL_TOSTRING): CachingIterator {} public function multiple(int $flags = MultipleIterator::MIT_NEED_ALL|MultipleIterator::MIT_KEYS_NUMERIC): MultipleIterator {} }
Backward Incompatible Changes
What breaks, and what is the justification for it?
Proposed PHP Version(s)
8.1.
RFC Impact
Should not impact existing functionality (other than making some of it easier to use).
Open Issues
Need to
Unaffected PHP Functionality
List existing areas/features of PHP that will not be changed by the RFC.
This helps avoid any ambiguity, shows that you have thought deeply about the RFC's impact, and helps reduces mail list noise.
Future Scope
This section details areas where the feature might be improved in future, but that are not currently proposed in this RFC.
Proposed Voting Choices
Include these so readers know where you are heading and can discuss the proposed voting options.
Patches and Tests
Links to any external patches and tests go here.
If there is no patch, make it clear who will create a patch, or whether a volunteer to help with implementation is needed.
Make it clear if the patch is intended to be the final patch, or is just a prototype.
For changes affecting the core language, you should also provide a patch for the language specification.
Implementation
After the project is implemented, this section should contain
- the version(s) it was merged into
- a link to the git commit(s)
- a link to the PHP manual entry for the feature
- a link to the language specification section (if any)
References
Links to external references, discussions or RFCs
Rejected Features
Keep this updated with features that were discussed on the mail lists.