On 4/26/2013 5:14 PM, H. S. Teoh wrote:
Does VRP work only with literals, or does it work with general variables (by inferring from, say, if-conditions)?void func(int i) { ubyte b; if (i >= 0 && i < 256) { b = i; // OK without cast? } ... }
Such would require data flow analysis, which is beyond the scope of what the front end is designed to do. So, no, for the foreseeable future.