cpp/filesystem/file size

If does not exist, reports an error.

For a regular file, returns the size determined as if by reading the member of the structure obtained by POSIX  (symlinks are followed).

The result of attempting to determine the size of a directory (as well as any other file that is not a regular file or a symlink) is implementation-defined.

The non-throwing overload returns on errors.

Return value
The size of the file, in bytes.