1// 2003-02-26 Martin v. Loewis <martin@v.loewis.de> 2 3// Copyright (C) 2003 Free Software Foundation, Inc. 4// 5// This file is part of the GNU ISO C++ Library. This library is free 6// software; you can redistribute it and/or modify it under the 7// terms of the GNU General Public License as published by the 8// Free Software Foundation; either version 2, or (at your option) 9// any later version. 10 11// This library is distributed in the hope that it will be useful, 12// but WITHOUT ANY WARRANTY; without even the implied warranty of 13// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14// GNU General Public License for more details. 15 16// You should have received a copy of the GNU General Public License along 17// with this library; see the file COPYING. If not, write to the Free 18// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, 19// USA. 20 21// IA 64 C++ ABI - 5.1 External Names (a.k.a. Mangling) 22 23#include <testsuite_hooks.h> 24 25// c++/8897 26int main() 27{ 28 using namespace __gnu_test; 29 30 /* 31 template<typename T1> 32 struct A 33 { 34 template<typename T2> 35 operator T2(); 36 }; 37 38 A<float> a; 39 (int)a; <-- that function. 40 */ 41 /* 42 Using "operator int()" is ambigious because that 43 could be either: 44 45 operator int(); 46 47 or 48 49 template<typename T> 50 operator T(); 51 with T = int. 52 53 - Carlo Wood 54 */ 55 // cplus-dem FAIL 56 // icc FAIL 57 // new __cxa_demangle FAIL 58 verify_demangle("_ZN1AIfEcvT_IiEEv", "A<float>::operator int<int>()"); 59 60 return 0; 61} 62