November 21, 2013
https://d.puremagic.com/issues/show_bug.cgi?id=10018


yebblies <yebblies@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
                 CC|                            |yebblies@gmail.com
         Resolution|                            |WORKSFORME


--- Comment #7 from yebblies <yebblies@gmail.com> 2013-11-22 03:11:57 EST ---
This seems to work just fine:

void main()
{
    immutable int i = 1;
    byte x = i;
}

-- 
Configure issuemail: https://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
March 16, 2014
https://d.puremagic.com/issues/show_bug.cgi?id=10018



--- Comment #8 from bearophile_hugs@eml.cc 2014-03-16 08:49:12 PDT ---
The value range of immutable variables is not yet propagated (see Issue 10594
):


void main(in string[] args) {
    immutable ushort x = args.length % 5;
    immutable ubyte y = x;
}


DMD 2.066alpha gives:

temp.d(3,25): Error: cannot implicitly convert expression (x) of type
immutable(ushort) to immutable(ubyte)

-- 
Configure issuemail: https://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------