about summary refs log tree commit diff
path: root/src/libstd
diff options
context:
space:
mode:
authorCameron Zwarich <zwarich@mozilla.com>2014-07-30 13:36:21 -0700
committerCameron Zwarich <zwarich@mozilla.com>2014-07-30 13:36:21 -0700
commit8da03d9771bc827eae713d16bca7bec4c5fe6a10 (patch)
treeba194b28561175e8d3614ce76bd74e24cbb87f82 /src/libstd
parent5ebf4813a6503d5312f457b8a6ba7b6998a45f2b (diff)
downloadrust-8da03d9771bc827eae713d16bca7bec4c5fe6a10.tar.gz
rust-8da03d9771bc827eae713d16bca7bec4c5fe6a10.zip
Library changes for RFC #43
Diffstat (limited to 'src/libstd')
-rw-r--r--src/libstd/collections/lru_cache.rs3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/libstd/collections/lru_cache.rs b/src/libstd/collections/lru_cache.rs
index 45e971a675f..32a16053fff 100644
--- a/src/libstd/collections/lru_cache.rs
+++ b/src/libstd/collections/lru_cache.rs
@@ -331,7 +331,8 @@ impl<K, V> Drop for LruCache<K, V> {
         unsafe {
             let node: Box<LruEntry<K, V>> = mem::transmute(self.head);
             // Prevent compiler from trying to drop the un-initialized field in the sigil node.
-            let box LruEntry { key: k, value: v, .. } = node;
+            let box internal_node = node;
+            let LruEntry { next: _, prev: _, key: k, value: v } = internal_node;
             mem::forget(k);
             mem::forget(v);
         }