Christopher Wright wrote:
It's an implicit narrowing conversion -- that involves data loss. This is a bug.

Actually, you said you had two methods, something like this:

void foo (byte i) {}
void foo (long i) {}
void main ()
{
    int a = 1;
    foo (a);
    byte b = a; // no casts
}

This example doesn't use typedefs but still complains about overloads. I find it odd that you can implicitly cast an arithmetic type of one width to another of a smaller width. I'm making a feature enhancement request for this.

Reply via email to