1// { dg-do compile } 2// { dg-options "-fabi-version=1 -Wabi" } 3 4// Copyright (C) 2003 Free Software Foundation, Inc. 5// Contributed by Nathan Sidwell 30 Nov 2003 <nathan@codesourcery.com> 6 7// PR 13241 8// mangled template arguments that are external objects incorrectly 9 10extern "C" void Foo (); 11namespace NMS 12{ 13 extern "C" int V; 14} 15 16template <void (*)()> struct S {}; 17template <int *> struct T {}; 18 19void f (S<Foo>){} // { dg-warning "mangled name" } 20// { dg-final { scan-assembler "\n_?_Z1f1SIXadL3FooEEE\[: \t\n\]" } } 21 22void g (T<&NMS::V>){} // { dg-warning "mangled name" } 23// { dg-final { scan-assembler "\n_?_Z1g1TIXadL_ZN3NMS1VEEEE\[: \t\n\]" } } 24