Skip to content

Explicitly convert streampos to streamoff #2587

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

Merged
merged 2 commits into from
Nov 9, 2020

Conversation

yecril71pl
Copy link
Contributor

  1. Explicitly convert streampos to streamoff.
  2. Print '\n' instead of endl.

The expression (cout << y) works as described only if no shift operator of streampos into ostream is defined.  That operator may be defined by user code and the result may be different.
Explicitly convert streampos to streamoff.
@PRMerger14
Copy link
Contributor

@yecril71pl : Thanks for your contribution! The author(s) have been notified to review your proposed change.

Copy link
Collaborator

@TylerMSFT TylerMSFT left a comment

Choose a reason for hiding this comment

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

Thanks for catching the second one. The first change is already live.

@TylerMSFT TylerMSFT merged commit 888d3ed into MicrosoftDocs:master Nov 9, 2020
@yecril71pl yecril71pl deleted the patch-2 branch November 9, 2020 21:47
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.

4 participants