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++/45588
[pf3gnuchains/gcc-fork.git]
/
gcc
/
testsuite
/
g++.dg
/
warn
/
Wunused-var-15.C
1
// PR c++/45588
2
// { dg-do compile }
3
// { dg-options "-Wunused" }
4
5
void bar (unsigned char *);
6
7
template <int N>
8
struct S
9
{
10
static const int k = 6;
11
};
12
13
template <int N>
14
const int S<N>::k;
15
16
template <int N>
17
void
18
foo ()
19
{
20
const int i = S<N>::k;
21
unsigned char a[i];
22
bar (a);
23
}
24
25
void
26
baz ()
27
{
28
foo<0> ();
29
}