]> git.lizzy.rs Git - rust.git/commitdiff
Use 8-byte pointers on 32-bit hosts for now.
authorScott Olson <scott@solson.me>
Fri, 15 Apr 2016 09:28:10 +0000 (03:28 -0600)
committerScott Olson <scott@solson.me>
Fri, 15 Apr 2016 09:28:18 +0000 (03:28 -0600)
This will be target-dependent and host-independent eventually.

src/memory.rs

index b99dae15970f88c594409338ce92733570fec37c..14aa4f9d799ec7634d687e8b104ed8fb593e0647 100644 (file)
@@ -102,8 +102,9 @@ pub fn new() -> Self {
             alloc_map: HashMap::new(),
             next_id: AllocId(0),
 
-            // TODO(tsion): Should this be host's or target's usize?
-            pointer_size: mem::size_of::<usize>(),
+            // FIXME(tsion): This should work for both 4 and 8, but it currently breaks some things
+            // when set to 4.
+            pointer_size: 8,
         }
     }