fn close_upvalues(&mut self, last: usize) {
        let last: *mut Value = &mut self.stack[last] as _;

        while let Some(upvalue) = self.open_upvalues.pop() {
            let u = unsafe { upvalue.as_mut() }
                .expect("null upvalue in open_upvalues");

            if u.location() >= last {
                u.close();
            } else {
                self.open_upvalues.push(upvalue);
                break;
            }
        }
    }
/// Traverse `open_upvalues` and pop and close upvalues.
///
/// We want to close upvalues which are at or past `last`.
Traverse `open_upvalues` and pop and close upvalues.
We want to close upvalues which are at or past `last`.
Traverse ` open_upvalues ` and pop and close upvalues . We want to close upvalues which are at or past ` last ` .
fn close_upvalues(&mut self, last: usize) {
        let last: *mut Value = &mut self.stack[last] as _;
        while let Some(upvalue) = self.open_upvalues.pop() {
            let u = unsafe { upvalue.as_mut() }
                .expect("null upvalue in open_upvalues");
            if u.location() >= last {
                u.close();
            } else {
                self.open_upvalues.push(upvalue);
                break;
            }
        }
    }
fn close_upvalues ( & mut self , last : usize ) { let last : * mut Value = & mut self . stack [ last ] as _ ; while let Some ( upvalue ) = self . open_upvalues . pop ( ) { let u = unsafe { upvalue . as_mut ( ) } . expect ( " " ) ; if u . location ( ) >= last { u . close ( ) ; } else { self . open_upvalues . push ( upvalue ) ; break ; } } }
Traverse `open_upvalues` and pop and close upvalues.
Traverse ` open_upvalues ` and pop and close upvalues .
&mut self
last
usize