repo.or.cz
/
gcc.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
Fortran: Fix PR 47485.
[gcc.git]
/
gcc
/
testsuite
/
g++.dg
/
warn
/
Wunused-var-15.C
blob
9782ccbd9a7c85cb9208c7c1395d946bfb9d19ac
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
}