31 Input/output library [input.output]

31.12 File systems [filesystems]

31.12.13 Filesystem operation functions [fs.op.funcs]

31.12.13.34 Resize file [fs.op.resize.file]

void filesystem::resize_file(const path& p, uintmax_t new_size); void filesystem::resize_file(const path& p, uintmax_t new_size, error_code& ec) noexcept;
Effects: Causes the size that would be returned by file_size(p) to be equal to new_size, as if by POSIX truncate().
Throws: As specified in [fs.err.report].