[Issue 5995] string append negative integer causes segfault

d-bugmail at puremagic.com d-bugmail at puremagic.com
Mon May 16 11:30:58 PDT 2011


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



--- Comment #8 from Steven Schveighoffer <schveiguy at yahoo.com> 2011-05-16 11:26:52 PDT ---
(In reply to comment #6)
> void main(){
>     uint i=-1;  //fine
>     dchar c=-1; //compile time error
> }

Just tried this and it indeed produces an error:

Error: cannot implicitly convert expression (-1) of type int to dchar

So I wonder why this works?  Seems inconsistent:

int i = -1;
dchar c = i;

Also, the reporter's issue seems to be inconsistent with that error.

-- 
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