[Issue 10093] wrong unsigned arithmetic

d-bugmail at puremagic.com d-bugmail at puremagic.com
Thu May 16 11:58:26 PDT 2013


http://d.puremagic.com/issues/show_bug.cgi?id=10093



--- Comment #6 from 9999 <sibaqexozequgaba at tempomail.fr> 2013-05-16 11:58:25 PDT ---
> We don't talk about implicitly converting -1 to unsigned, right? That's a different case.
^ Am I missing something? ^

We're not talking about:
func:
void SetText(char* text, uint len);
call:
SetText(text, -1);
^ here -1 is a special constant meaning e.g. calculate the len of a null
terminated string.

We're talking about:
uint len = strlen(text);
// ...
Func(-len); // Why would you ever need this?

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


More information about the Digitalmars-d-bugs mailing list