diff options
| author | Gareth Daniel Smith <garethdanielsmith@gmail.com> | 2012-07-04 22:53:12 +0100 | 
|---|---|---|
| committer | Brian Anderson <banderson@mozilla.com> | 2012-07-04 19:18:13 -0700 | 
| commit | be0141666dd12316034499db12ee9fcf9ba648dd (patch) | |
| tree | 7d4c985a73e9a85de0e6c1bf2beeed44ebbd0102 /src/libcore/sys.rs | |
| parent | bfa43ca3011bd1296cb1797ad3ea1c5dc4056749 (diff) | |
| download | rust-be0141666dd12316034499db12ee9fcf9ba648dd.tar.gz rust-be0141666dd12316034499db12ee9fcf9ba648dd.zip  | |
convert doc-attributes to doc-comments using ./src/etc/sugarise-doc-comments.py (and manually tweaking) - for issue #2498
Diffstat (limited to 'src/libcore/sys.rs')
| -rw-r--r-- | src/libcore/sys.rs | 32 | 
1 files changed, 16 insertions, 16 deletions
diff --git a/src/libcore/sys.rs b/src/libcore/sys.rs index 992083c484b..e99860a6250 100644 --- a/src/libcore/sys.rs +++ b/src/libcore/sys.rs @@ -1,4 +1,4 @@ -#[doc = "Misc low level stuff"]; +//! Misc low level stuff export type_desc; export get_type_desc; @@ -39,38 +39,38 @@ extern mod rusti { fn min_align_of<T>() -> uint; } -#[doc = " -Returns a pointer to a type descriptor. - -Useful for calling certain function in the Rust runtime or otherwise -performing dark magick. -"] +/** + * Returns a pointer to a type descriptor. + * + * Useful for calling certain function in the Rust runtime or otherwise + * performing dark magick. + */ pure fn get_type_desc<T>() -> *type_desc { unchecked { rusti::get_tydesc::<T>() as *type_desc } } -#[doc = "Returns the size of a type"] +/// Returns the size of a type #[inline(always)] pure fn size_of<T>() -> uint { unchecked { rusti::size_of::<T>() } } -#[doc = " -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. -"] +/** + * 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. + */ pure fn min_align_of<T>() -> uint { unchecked { rusti::min_align_of::<T>() } } -#[doc = "Returns the preferred alignment of a type"] +/// Returns the preferred alignment of a type pure fn pref_align_of<T>() -> uint { unchecked { rusti::pref_align_of::<T>() } } -#[doc = "Returns the refcount of a shared box (as just before calling this)"] +/// Returns the refcount of a shared box (as just before calling this) pure fn refcount<T>(+t: @T) -> uint { unsafe { let ref_ptr: *uint = unsafe::reinterpret_cast(t);  | 
