Skip to content

Commit e205a2e

Browse files
committed
ObjFW BOOL support
1 parent b412897 commit e205a2e

1 file changed

Lines changed: 8 additions & 2 deletions

File tree

objc-sys/src/types.rs

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -55,10 +55,16 @@ mod inner {
5555
pub type BOOL = u8;
5656
}
5757

58-
// ObjFW???
58+
// ObjFW
5959
#[cfg(objfw)]
6060
mod inner {
61-
pub type BOOL = todo!();
61+
// Defined in ObjFW-RT.h
62+
// C: signed char
63+
// This has changed since v0.90, but we don't support that yet.
64+
pub type BOOL = i8;
65+
66+
// Note that ObjFW uses `bool` in return types, but that doesn't change
67+
// the ABI, so we'll just use `BOOL` there for ease of use.
6268
}
6369

6470
/// The Objective-C `BOOL` type.

0 commit comments

Comments
 (0)