Sign in
android
/
toolchain
/
rustc
/
ee32a8b31351dab7161ea2edd877e46fc49c72d0
/
.
/
tests
/
ui
/
issues
/
issue-40085.rs
blob: 132044cfd6dce3e36f2acc205a34bed00eaa0815 [
file
] [
log
] [
blame
]
// run-pass
use
std
::
ops
::
Index
;
fn
bar
()
{}
static
UNIT
:
()
=
();
struct
S
;
impl
Index
<
fn
()>
for
S
{
type
Output
=
();
fn
index
(&
self
,
_
:
fn
())
->
&()
{
&
UNIT
}
}
fn
main
()
{
S
.
index
(
bar
);
S
[
bar
];
}