diff options
author | bkoz <bkoz@138bc75d-0d04-0410-961f-82ee72b054a4> | 2010-11-04 05:53:05 +0000 |
---|---|---|
committer | bkoz <bkoz@138bc75d-0d04-0410-961f-82ee72b054a4> | 2010-11-04 05:53:05 +0000 |
commit | f07666e1203a50ae445025050b7e12311db6bbd0 (patch) | |
tree | 71958eff5a01ab8a0f3b6c5a100767f03b50b41f /libstdc++-v3/testsuite/20_util/tuple | |
parent | 290767fbc92c5971e9db1dce9e0f52f3e0b13999 (diff) | |
download | gcc-f07666e1203a50ae445025050b7e12311db6bbd0.tar.gz |
2010-11-03 Benjamin Kosnik <bkoz@redhat.com>
* include/std/tuple (tuple): Make default constructors constexpr.
* testsuite/20_util/tuple/cons/constexpr.cc: Add.
* testsuite/18_support/initializer_list/requirements/
constexpr_functions.cc: Add.
* testsuite/18_support/initializer_list/constexpr.cc: Add.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@166301 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libstdc++-v3/testsuite/20_util/tuple')
-rw-r--r-- | libstdc++-v3/testsuite/20_util/tuple/cons/constexpr.cc | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/libstdc++-v3/testsuite/20_util/tuple/cons/constexpr.cc b/libstdc++-v3/testsuite/20_util/tuple/cons/constexpr.cc new file mode 100644 index 00000000000..a4666e5d5cd --- /dev/null +++ b/libstdc++-v3/testsuite/20_util/tuple/cons/constexpr.cc @@ -0,0 +1,29 @@ +// { dg-do compile } +// { dg-options "-std=gnu++0x" } + +// Copyright (C) 2010 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 3, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING3. If not see +// <http://www.gnu.org/licenses/>. + +#include <memory> +#include <testsuite_common_types.h> + +int main() +{ + __gnu_test::constexpr_default_constructible test; + test.operator()<std::tuple<int, int>>(); + return 0; +} |