std::filesystem::filesystem_error::operator=

来自cppreference.com
 
 
 
 
filesystem_error& operator=( const filesystem_error& other ) noexcept;
(C++17 起)

other 的内容赋值内容。若 *thisother 均拥有动态类型 std::filesystem::filesystem_error,则赋值后 std::strcmp(what(), other.what()) == 0

目录

[编辑] 参数

other - 用以赋值的另一 filesystem_error 对象

[编辑] 返回值

*this

[编辑] 注解

典型的实现在引用计数的存储中存储 path1()path2() 所引用的 path 对象。结果是 *thisother 通常在赋值后共享其 path 对象。

[编辑] 示例