Misc low level stuff
condition
type_desc
methods for lock_and_signal
methods for condition
get_type_desc
- Returns a pointer to a type descriptor.log_str
min_align_of
- Returns the ABI-required minimum alignment of a typepref_align_of
- Returns the preferred alignment of a typerefcount
- Returns the refcount of a shared box (as just before calling this)size_of
- Returns the size of a typecondition
condition_(rust_cond_lock)
type_desc
type_desc({first_param: **libc::c_int, size: libc::size_t, align: libc::size_t,})
methods for lock_and_signal
lock
unsafe fn lock<T>(f: fn() -> T) -> T
lock_cond
unsafe fn lock_cond<T>(f: fn(condition) -> T) -> T
methods for condition
wait
fn wait()
signal
fn signal() -> bool
get_type_desc
pure fn get_type_desc<T>() -> *type_desc
Returns a pointer to a type descriptor.
Useful for calling certain function in the Rust runtime or otherwise performing dark magick.
log_str
pure fn log_str<T>(t: T) -> str
min_align_of
pure fn min_align_of<T>() -> uint
Returns the ABI-required minimum alignment of a type
This is the alignment used for struct fields. It may be smaller than the preferred alignment.
pref_align_of
pure fn pref_align_of<T>() -> uint
Returns the preferred alignment of a type
refcount
pure fn refcount<T>(+t: @T) -> uint
Returns the refcount of a shared box (as just before calling this)
size_of
pure fn size_of<T>() -> uint
Returns the size of a type