Sign in
gnu
/
gcc
/
1f16a020acbea0af26209478990b83b1a1ba3a2b
/
.
/
gcc
/
testsuite
/
g++.dg
/
template
/
scope6.C
blob: 6d28fb2ec9e0dc8fb8ee74e00880b12209c4ba65 [
file
] [
log
] [
blame
]
// PR c++/89831
struct
Q
{
int
operator
[](
int
i
)
{
return
0
;
}
int
operator
[](
int
i
)
const
{
return
0
;
}
};
struct
Base
{
Q x
;
};
struct
X
:
public
Base
{
template
<
typename
T
>
void
f
(
T
)
const
{
int
q
=
Base
::
x
[
0
];
}
};
int
main
()
{
X
().
f
(
3
);
}