What    |Removed                     |Added
                 CC|                            |

--- Comment #1 from 2012-10-27 13:21:36 PDT ---
I don't understand, why should this work?

D arrays are not the same as C arrays; casting an int into an array does not
magically make it an array of bytes.

If you want to get the byte representation, you need to do something like this:

int a = 1234;
ubyte* ptr = cast(ubyte*)&a;
writeln(ptr[0 .. int.sizeof]);

Note, though, that this is unsafe, and is generally not recommended in D code,
unless you're writing low-level code.

Configure issuemail:
------- You are receiving this mail because: -------

Reply via email to