Skip to content
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

Fix infinite recursion in writing non-null optional into stream_to #364

Merged
merged 1 commit into from
Aug 15, 2020

Conversation

georgthegreat
Copy link
Contributor

@georgthegreat georgthegreat commented Aug 15, 2020

Found while experimenting with #357

@jtv jtv merged commit f74bc19 into jtv:master Aug 15, 2020
@jtv
Copy link
Owner

jtv commented Aug 15, 2020

You're right — that was a crazy oversight. And I honestly wasn't expecting that call to be able to recurse, but of course the argument is a const reference, so the compiler can promote the value to a std::optional.

Thanks for the fix.

jtv added a commit that referenced this pull request Aug 15, 2020
@georgthegreat georgthegreat deleted the patch-1 branch August 17, 2020 18:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants