Implement LWG 2787 - [file_status.cons] is inconsistent

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@297071 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Eric Fiselier 2017-03-06 21:02:06 +00:00
parent b537d38bb2
commit 7c7df6461c
3 changed files with 7 additions and 5 deletions

View File

@ -408,8 +408,10 @@ class _LIBCPP_TYPE_VIS file_status
public:
// constructors
_LIBCPP_INLINE_VISIBILITY
explicit file_status(file_type __ft = file_type::none,
perms __prms = perms::unknown) _NOEXCEPT
file_status() _NOEXCEPT : file_status(file_type::none) {}
_LIBCPP_INLINE_VISIBILITY
explicit file_status(file_type __ft,
perms __prms = perms::unknown) _NOEXCEPT
: __ft_(__ft), __prms_(__prms)
{}

View File

@ -30,8 +30,8 @@ int main() {
{
static_assert(std::is_nothrow_default_constructible<file_status>::value,
"The default constructor must be noexcept");
static_assert(!test_convertible<file_status>(),
"The default constructor must be explicit");
static_assert(test_convertible<file_status>(),
"The default constructor must not be explicit");
const file_status f;
assert(f.type() == file_type::none);
assert(f.permissions() == perms::unknown);

View File

@ -439,7 +439,7 @@
<tr><td><a href="http://wg21.link/LWG2784">2784</a></td><td>Resolution to LWG 2484 is missing "otherwise, no effects" and is hard to parse</td><td>Kona</td><td></td></tr>
<tr><td><a href="http://wg21.link/LWG2785">2785</a></td><td>quoted should work with basic_string_view</td><td>Kona</td><td></td></tr>
<tr><td><a href="http://wg21.link/LWG2786">2786</a></td><td>Annex C should mention shared_ptr changes for array support</td><td>Kona</td><td></td></tr>
<tr><td><a href="http://wg21.link/LWG2787">2787</a></td><td>&sect;[file_status.cons] doesn't match class definition</td><td>Kona</td><td></td></tr>
<tr><td><a href="http://wg21.link/LWG2787">2787</a></td><td>&sect;[file_status.cons] doesn't match class definition</td><td>Kona</td><td>Complete</td></tr>
<tr><td><a href="http://wg21.link/LWG2788">2788</a></td><td>basic_string range mutators unintentionally require a default constructible allocator</td><td>Kona</td><td></td></tr>
<tr><td><a href="http://wg21.link/LWG2789">2789</a></td><td>Equivalence of contained objects</td><td>Kona</td><td></td></tr>
<tr><td><a href="http://wg21.link/LWG2790">2790</a></td><td>Missing specification of istreambuf_iterator::operator-&gt;</td><td>Kona</td><td></td></tr>