Skip to content

Commit

Permalink
Comment on future use of "C-unwind" ABI (issue #7)
Browse files Browse the repository at this point in the history
  • Loading branch information
nvzqz committed Dec 7, 2020
1 parent 174554e commit cc39e21
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/foundation/ns_exception/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -61,8 +61,8 @@ impl NSException {
/// See [documentation](https://developer.apple.com/documentation/foundation/nsexception/1416135-raise).
#[inline]
pub fn raise(&self) -> ! {
// TODO(#7): Use "C-unwind" ABI when stable.
extern "C" {
// TODO: Define unwind ABI.
fn objc_exception_throw(exception: &NSException) -> !;
}
unsafe { objc_exception_throw(self) }
Expand Down
1 change: 1 addition & 0 deletions src/objc/msg/get_fn.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#[allow(unused)]
use std::{any::TypeId, mem};

// TODO(#7): Use "C-unwind" ABI when stable.
#[allow(unused)]
extern "C" {
fn objc_msgSend();
Expand Down
1 change: 1 addition & 0 deletions src/objc/msg/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,7 @@ macro_rules! impl_msg_args_base {
sel: SEL,
($($arg,)*): Self,
) -> Ret {
// TODO(#7): Use "C-unwind" ABI when stable.
let msg_send: unsafe extern "C" fn(*const c_void, SEL $(, $arg)*) -> Ret
= mem::transmute(get_fn::msg_send_fn::<Ret>());

Expand Down

0 comments on commit cc39e21

Please sign in to comment.