OSDN Git Service
(root)
/
pf3gnuchains
/
gcc-fork.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
history
|
raw
|
HEAD
PR c++/33501
[pf3gnuchains/gcc-fork.git]
/
gcc
/
testsuite
/
g++.dg
/
template
/
incomplete5.C
1
// PR c++/33501
2
// { dg-do compile }
3
4
class A; // { dg-error "forward declaration" }
5
6
template <typename T> struct X
7
{
8
static int f (T);
9
static const T &make ();
10
static const bool value = sizeof (f (make ())) == sizeof (int); // { dg-error "invalid use of incomplete type|initializing argument" }
11
};
12
13
int
14
main ()
15
{
16
return X <A>::value;
17
}