Skip to content

Documented the support of iterators in write() and writeln() #9776

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 2 commits into from

Conversation

javiereguiluz
Copy link
Member

This fixes #9634.

console.rst Outdated
@@ -101,6 +101,10 @@ messages to the console)::
'',
]);

// the value returned by someMethod() can be an iterator that
// generates and returns the messages with the 'yield' PHP keyword
$output->writeln($this->someMethod());
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would it be an idea to mention the Iterator? http://php.net/manual/en/class.iterator.php Could hint towards yield support next to that, but yield is a more complex concept than just an iterator

javiereguiluz added a commit that referenced this pull request May 22, 2018
…n() (javiereguiluz)

This PR was squashed before being merged into the 4.1 branch (closes #9776).

Discussion
----------

Documented the support of iterators in write() and writeln()

This fixes #9634.

Commits
-------

f9b9c10 Documented the support of iterators in write() and writeln()
@javiereguiluz javiereguiluz deleted the fix_9634 branch May 24, 2018 16:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants