Closed
Description
Running the following in release mode causes a segfault:
extern crate gc;
use gc::Gc;
use std::{mem, usize};
fn main() {
let a = Gc::new("abc".to_string());
let a2 = a.clone();
for _ in 0..usize::MAX {
mem::forget(a.clone());
}
drop(a2);
gc::force_collect();
println!("{:?}", *a);
}
This is the same issue that was fixed in rust-lang/rust#27174. I have a fix incoming.
Metadata
Metadata
Assignees
Labels
No labels