doc: Fix transmute example
This commit is contained in:
parent
5003f607ec
commit
9721732976
@ -66,7 +66,10 @@ pub unsafe fn bump_box_refcount<T>(t: @T) { forget(t); }
|
||||
*
|
||||
* # Example
|
||||
*
|
||||
* assert!(transmute("L") == ~[76u8, 0u8]);
|
||||
* ~~~ {.rust}
|
||||
* let v: &[u8] = transmute("L");
|
||||
* assert!(v == [76u8]);
|
||||
* ~~~
|
||||
*/
|
||||
#[inline]
|
||||
pub unsafe fn transmute<L, G>(thing: L) -> G {
|
||||
|
Loading…
x
Reference in New Issue
Block a user