]>
git.proxmox.com Git - rustc.git/blob - tests/ui/nll/issue-53773.rs
2 struct ArchiveIterator
<'a
> {
5 struct ArchiveChild
<'a
> {
10 raw
: &'
static mut Archive
,
13 raw
: &'a
mut ArchiveIterator
<'a
>,
16 raw
: &'a
mut ArchiveChild
<'a
>,
20 pub fn iter(&self) -> Iter
<'_
> {
27 impl<'a
> Drop
for C
<'a
> {
31 impl<'a
> Iterator
for Iter
<'a
> {
33 fn next(&mut self) -> Option
<C
<'a
>> {
38 fn error(archive
: &A
) {
39 let mut members
: Vec
<&mut ArchiveChild
<'_
>> = vec
![];
40 for child
in archive
.iter() {
41 members
.push(child
.raw
);
42 //~^ ERROR borrow may still be in use when destructor runs [E0713]