From 466f0653a31817b6201c6e01d49e6e7f76b98cfb Mon Sep 17 00:00:00 2001 From: Michael Park Date: Wed, 1 Mar 2017 01:07:56 +0000 Subject: [PATCH] Updated the XFAIL comment in variant tests. Summary: `ConstexprTestTypes::NoCtors` is an aggregate type (and consequently a literal type) in C++17, but not in C++14 since it has a base class. This patch updates the comment to accurately describe the reason for the XFAIL. Reviewers: EricWF Reviewed By: EricWF Differential Revision: https://reviews.llvm.org/D30481 llvm-svn: 296558 --- .../variant/variant.variant/variant.status/index.pass.cpp | 5 ++++- .../variant.status/valueless_by_exception.pass.cpp | 5 ++++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/libcxx/test/std/utilities/variant/variant.variant/variant.status/index.pass.cpp b/libcxx/test/std/utilities/variant/variant.variant/variant.status/index.pass.cpp index 6675b5f2b2ba..a4ea592709e3 100644 --- a/libcxx/test/std/utilities/variant/variant.variant/variant.status/index.pass.cpp +++ b/libcxx/test/std/utilities/variant/variant.variant/variant.status/index.pass.cpp @@ -10,7 +10,10 @@ // UNSUPPORTED: c++98, c++03, c++11, c++14 -// The following compilers don't allow constexpr variables of non-literal type. +// The following compilers don't consider a type an aggregate type (and +// consequently not a literal type) if it has a base class at all. +// In C++17, an aggregate type is allowed to have a base class if it's not +// virtual, private, nor protected (e.g. ConstexprTestTypes:::NoCtors). // XFAIL: gcc-5, gcc-6 // XFAIL: clang-3.5, clang-3.6, clang-3.7, clang-3.8 // XFAIL: apple-clang-6, apple-clang-7, apple-clang-8 diff --git a/libcxx/test/std/utilities/variant/variant.variant/variant.status/valueless_by_exception.pass.cpp b/libcxx/test/std/utilities/variant/variant.variant/variant.status/valueless_by_exception.pass.cpp index a0c57e132403..e58b052f9cef 100644 --- a/libcxx/test/std/utilities/variant/variant.variant/variant.status/valueless_by_exception.pass.cpp +++ b/libcxx/test/std/utilities/variant/variant.variant/variant.status/valueless_by_exception.pass.cpp @@ -10,7 +10,10 @@ // UNSUPPORTED: c++98, c++03, c++11, c++14 -// The following compilers don't allow constexpr variables of non-literal type. +// The following compilers don't consider a type an aggregate type (and +// consequently not a literal type) if it has a base class at all. +// In C++17, an aggregate type is allowed to have a base class if it's not +// virtual, private, nor protected (e.g. ConstexprTestTypes:::NoCtors). // XFAIL: gcc-5, gcc-6 // XFAIL: clang-3.5, clang-3.6, clang-3.7, clang-3.8 // XFAIL: apple-clang-6, apple-clang-7, apple-clang-8