Test: the margin helper lets go of its fields by name, so none reads as unused
lavapipe's build of the runtime's tests warned that AtTheMargin's opener, used and ram are never read: let_go dropped them through the whole struct. It now takes them out by name and drops them in the same order, objects first. (cherry picked from commit 6ed67830696a855c7eda362c6c476e666793aa15)
This commit is contained in:
1 parent
0b94f4196f
commit
ca3a20c37c
1 file changed
+8
-2
@@ -680,8 +680,14 @@ impl AtTheMargin {
|
||||
|
||||
/// Let go of the RAM's use, the objects first: its keep-alive goes after the last chunk.
|
||||
fn let_go(self, objects: Vec<Buffer>) {
|
||||
let dropped = Arc::clone(&self.dropped);
|
||||
drop((objects, self));
|
||||
let AtTheMargin {
|
||||
opener,
|
||||
used,
|
||||
ram,
|
||||
dropped,
|
||||
..
|
||||
} = self;
|
||||
drop((objects, opener, used, ram));
|
||||
assert!(
|
||||
settles(&dropped),
|
||||
"the keep-alive goes after the last chunk"
|
||||
|
||||
Reference in new issue
Block a user