Add noexcept to filesystem::path query functions
authorJonathan Wakely <jwakely@redhat.com>
Sat, 9 Feb 2019 00:25:39 +0000 (00:25 +0000)
committerJonathan Wakely <redi@gcc.gnu.org>
Sat, 9 Feb 2019 00:25:39 +0000 (00:25 +0000)
commit4fe5c8c730ead2286103b95a4226f9d23b95a68a
tree0b7f248aca7388225e5d71b337a99568ac7771e5
parent5b0bf81512c506d863a48fd0aeea4812c1b35a28
Add noexcept to filesystem::path query functions

In the standard these member functions are specified in terms of the
potentially-throwing path decompositions functions, but we implement
them without constructing any new paths or doing anything else that can
throw.

PR libstdc++/71044
* include/bits/fs_path.h (path::has_root_name)
(path::has_root_directory, path::has_root_path)
(path::has_relative_path, path::has_parent_path)
(path::has_filename, path::has_stem, path::has_extension)
(path::is_absolute, path::is_relative, path::_M_find_extension): Add
noexcept.
* src/c++17/fs_path.cc (path::has_root_name)
(path::has_root_directory, path::has_root_path)
(path::has_relative_path, path::has_parent_path)
(path::has_filename, path::_M_find_extension): Add noexcept.

From-SVN: r268713
libstdc++-v3/ChangeLog
libstdc++-v3/include/bits/fs_path.h
libstdc++-v3/src/c++17/fs_path.cc