Skip to content

Commit

Permalink
Fix GNUStep linking
Browse files Browse the repository at this point in the history
  • Loading branch information
madsmtm committed Feb 22, 2022
1 parent c142d8f commit 30f4c01
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion objc2/benches/autorelease.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,12 @@ extern "C" {}

const BYTES: &[u8] = &[1, 2, 3, 4, 5, 6, 7, 8, 9, 10];

fn empty() {}
fn empty() {
#[cfg(gnustep)]
unsafe {
objc2::__gnustep_hack::get_class_to_force_linkage()
};
}

fn pool_cleanup() {
autoreleasepool(|_| {})
Expand Down

0 comments on commit 30f4c01

Please sign in to comment.