// { dg-options "-std=gnu++0x" } // { dg-require-effective-target dfp } // 2011-02-23 Benjamin Kosnik // // Copyright (C) 2011 Free Software Foundation // // 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 // . #include #include #include template std::string gen_type_info() { std::string s1 = typeid(_Tp).name(); std::string s2 = typeid(_Tp*).name(); std::string s3 = typeid(const _Tp*).name(); return std::max(std::max(s1, s2), s3); } // libstdc++/43622, others int main() { gen_type_info(); gen_type_info(); gen_type_info(); gen_type_info(); gen_type_info(); gen_type_info(); gen_type_info(); gen_type_info(); gen_type_info(); gen_type_info(); gen_type_info(); gen_type_info(); gen_type_info(); gen_type_info(); gen_type_info(); gen_type_info(); gen_type_info(); gen_type_info(); gen_type_info(); gen_type_info(); // decimal gen_type_info(); gen_type_info(); gen_type_info(); // attributes #if 0 typedef int ti_type __attribute__((__mode__(TI))); gen_type_info(); typedef float tf_type __attribute__((__mode__(TF))); gen_type_info(); #endif return 0; }