aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.9/gcc/testsuite/g++.dg/cpp0x/pr50901.C
blob: de82435a43969dae4a173721a65ec62ffc038cf8 (plain)
1
2
3
4
5
6
7
8
9
// { dg-do compile { target c++11 } }

template<class T> int foo(int a)
{
  const unsigned b = a < 0 ? -a : a;
  return 0;
}

int i = foo<float>(1);