Allocator Designs
This commit is contained in:
@@ -54,6 +54,16 @@ fn many_boxes() {
|
||||
}
|
||||
}
|
||||
|
||||
#[test_case]
|
||||
fn many_boxes_long_lived() {
|
||||
let long_lived = Box::new(1);
|
||||
for i in 0..HEAP_SIZE {
|
||||
let x = Box::new(i);
|
||||
assert_eq!(*x, i);
|
||||
}
|
||||
assert_eq!(*long_lived, 1);
|
||||
}
|
||||
|
||||
#[panic_handler]
|
||||
fn panic(info: &PanicInfo) -> ! {
|
||||
anos::test_panic_handler(info)
|
||||
|
Reference in New Issue
Block a user