Files
cppdraft_translate/cppdraft/istream/assign.md
2025-10-25 03:02:53 +03:00

42 lines
1.1 KiB
Markdown
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

[istream.assign]
# 31 Input/output library [[input.output]](./#input.output)
## 31.7 Formatting and manipulators [[iostream.format]](iostream.format#istream.assign)
### 31.7.5 Input streams [[input.streams]](input.streams#istream.assign)
#### 31.7.5.2 Class template basic_istream [[istream]](istream#assign)
#### 31.7.5.2.3 Assignment and swap [istream.assign]
[🔗](#lib:operator=,basic_istream)
`basic_istream& operator=(basic_istream&& rhs);
`
[1](#1)
[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/iostreams.tex#L4479)
*Effects*: Equivalent to swap(rhs)[.](#1.sentence-1)
[2](#2)
[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/iostreams.tex#L4483)
*Returns*: *this[.](#2.sentence-1)
[🔗](#lib:swap,basic_istream)
`void swap(basic_istream& rhs);
`
[3](#3)
[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/iostreams.tex#L4494)
*Effects*: Calls basic_ios<charT, traits>::swap(rhs)[.](#3.sentence-1)
Exchanges the values returned by gcount() andrhs.gcount()[.](#3.sentence-2)