view gcc/testsuite/g++.old-deja/g++.pt/crash54.C @ 111:04ced10e8804

gcc 7
author kono
date Fri, 27 Oct 2017 22:46:09 +0900
parents
children
line wrap: on
line source

// { dg-do assemble  }
// Origin: Mark Mitchell <mark@codesourcery.com>

template <class T>
int g (T);

int j = g (3);

template <class T>
inline T f (T)
{
  return 2;
}

template <class T>
struct S
{
  static const int i;
};

template <class T>
const int S<T>::i = f (3);

template <class T>
int g (T)
{
  return S<double>::i;
}