aboutsummaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorAndrew Kelley <superjoe30@gmail.com>2017-03-31 06:18:20 -0400
committerAndrew Kelley <superjoe30@gmail.com>2017-03-31 06:18:20 -0400
commitf8e63c458478022813a67bfd5ee64bfad6eee82e (patch)
tree52952d63618068cbe76ee1175623e7f9e2976de2 /doc
parent3ca027ca8219dbdbb6467645944c4daada037f51 (diff)
downloadzig-f8e63c458478022813a67bfd5ee64bfad6eee82e.tar.gz
zig-f8e63c458478022813a67bfd5ee64bfad6eee82e.zip
change `@bitcast` to `@ptrcast`
See #290
Diffstat (limited to 'doc')
-rw-r--r--doc/langref.md7
1 files changed, 2 insertions, 5 deletions
diff --git a/doc/langref.md b/doc/langref.md
index 529191bf26..991471c015 100644
--- a/doc/langref.md
+++ b/doc/langref.md
@@ -634,9 +634,6 @@ calls the public `panic` function exposed in the root source file, or
if there is not one specified, invokes the one provided in
`std/special/panic.zig`.
-### @bitcast(comptime DestType: type, value: var) -> DestType
+### @ptrcast(comptime DestType: type, value: var) -> DestType
-Transmutes memory from one type to another without changing any bits.
-The source and destination types must have the same size. This function
-can be used to, for example, reinterpret a pointer, or convert a `f32` to a
-`u32`.
+Converts a pointer of one type to a pointer of another type.