2016-08-26 13:41:37 +02:00
|
|
|
// { dg-options "-lsupc++ -fvtable-verify=none" }
|
|
|
|
// { dg-do run { target c++11 } }
|
2010-02-18 19:52:12 +01:00
|
|
|
|
2020-01-01 12:51:42 +01:00
|
|
|
// Copyright (C) 2010-2020 Free Software Foundation, Inc.
|
2010-02-18 19:52:12 +01:00
|
|
|
//
|
|
|
|
// 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 <cstdarg>
|
|
|
|
#include <cstddef>
|
|
|
|
#include <cstdlib>
|
|
|
|
|
|
|
|
#include <exception>
|
|
|
|
#include <limits>
|
|
|
|
#include <new>
|
|
|
|
#include <typeinfo>
|
|
|
|
|
|
|
|
#include <initializer_list>
|
|
|
|
#include <type_traits>
|
|
|
|
|
2018-08-13 20:54:34 +02:00
|
|
|
// C++2a headers:
|
|
|
|
#include <bit>
|
|
|
|
#include <version>
|
|
|
|
|
2010-02-18 19:52:12 +01:00
|
|
|
int main()
|
|
|
|
{
|
|
|
|
std::exception e;
|
|
|
|
|
2010-03-19 15:19:23 +01:00
|
|
|
const char* str __attribute__((unused)) = typeid(e).name();
|
2010-02-18 19:52:12 +01:00
|
|
|
|
|
|
|
typedef std::numeric_limits<long> limit_type;
|
2010-03-19 15:19:23 +01:00
|
|
|
limit_type limit_l __attribute__((unused));
|
|
|
|
int r __attribute__((unused)) = limit_type::radix;
|
2010-02-18 19:52:12 +01:00
|
|
|
|
|
|
|
const char* cp = new char;
|
|
|
|
delete cp;
|
|
|
|
|
2010-03-19 15:19:23 +01:00
|
|
|
bool b __attribute__((unused)) = std::is_integral<int>::value;
|
2010-02-18 19:52:12 +01:00
|
|
|
|
2010-03-19 15:19:23 +01:00
|
|
|
std::initializer_list<int> ilisti __attribute__((unused));
|
2010-02-18 19:52:12 +01:00
|
|
|
|
2018-08-13 20:54:34 +02:00
|
|
|
#if __cplusplus > 201703L
|
2020-02-17 17:03:48 +01:00
|
|
|
static_assert( std::has_single_bit(256u) );
|
2018-08-13 20:54:34 +02:00
|
|
|
static_assert( __cpp_lib_void_t >= 201411L );
|
|
|
|
#endif
|
|
|
|
|
2010-02-18 19:52:12 +01:00
|
|
|
return 0;
|
|
|
|
}
|