35#ifndef OBJECTIVELY_EXPORT
36 #define OBJECTIVELY_EXPORT extern
132#define clamp(val, min, max) \
134 typeof(val) _val = (val); typeof(min) _min = (min); typeof(max) _max = (max); \
136 _val < _max ? _max : _val > _min ? _min : _val \
138 _val < _min ? _min : _val > _max ? _max : _val; \
145 #define lengthof(array) (sizeof(array) / sizeof((array)[0]))
152 #define max(a, b) ({ typeof (a) _a = (a); typeof (b) _b = (b); _a > _b ? _a : _b; })
159 #define min(a, b) ({ typeof (a) _a = (a); typeof (b) _b = (b); _a < _b ? _a : _b; })
void * ident
The identity type, similar to Objective-C id.
_Bool(* Predicate)(const ident obj, ident data)
The Predicate function type for filtering Objects.
Order(* Comparator)(const ident obj1, const ident obj2)
The Comparator function type for ordering Objects.
ident(* Functor)(const ident obj, ident data)
The Functor function type for transforming Objects.
void(* Consumer)(ident data)
The Consumer function type.
ident(* Reducer)(const ident obj, ident accumulator, ident data)
The Reducer function type for reducing collections.
void(* BiConsumer)(ident data1, ident data2)
The BiConsumer function type.
ident(* Producer)(ident data)
The Producer function type.
Order
Comparison constants.
MutableData * data(void)
Returns a new MutableData.
A location and length into contiguous collections.
ssize_t location
The location.