mirror of
https://github.com/darlinghq/darling-libcxx.git
synced 2025-03-03 09:17:09 +00:00
[libcxx] Fix test failure on GCC 4.9
GCC 4.9 seems to think that a constexpr default constructor implies the constructor to be noexcept. git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@348850 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
bca4d67c16
commit
649e69dd22
@ -18,12 +18,17 @@
|
||||
#include <utility>
|
||||
#include <type_traits>
|
||||
|
||||
#include "archetypes.hpp"
|
||||
|
||||
struct ThrowingDefault {
|
||||
ThrowingDefault() { }
|
||||
};
|
||||
|
||||
struct NonThrowingDefault {
|
||||
NonThrowingDefault() noexcept { }
|
||||
};
|
||||
|
||||
int main() {
|
||||
using NonThrowingDefault = NonThrowingTypes::DefaultOnly;
|
||||
using ThrowingDefault = NonTrivialTypes::DefaultOnly;
|
||||
|
||||
static_assert(!std::is_nothrow_default_constructible<std::pair<ThrowingDefault, ThrowingDefault>>::value, "");
|
||||
static_assert(!std::is_nothrow_default_constructible<std::pair<NonThrowingDefault, ThrowingDefault>>::value, "");
|
||||
static_assert(!std::is_nothrow_default_constructible<std::pair<ThrowingDefault, NonThrowingDefault>>::value, "");
|
||||
|
Loading…
x
Reference in New Issue
Block a user