Disable implicit conversion
Eugene
yes9111 at gmail.com
Mon Mar 7 02:33:28 PST 2011
Hi!
What I want to do is pretty simple. I need to subtract a ubyte from a
ubyte and store the result in a ubyte. The problem is that DMD
implicitly wants to convert the ubytes into an integer, so it fails
when attempting to store the result into a ubyte. (Int cannot be
converted to ubyte?)
The error message I get:
src\test.d(26): Error: cannot implicitly convert expression
(cast(int)u2 - cast(int)u1) of type int to ubyte
More information about the Digitalmars-d
mailing list