digitalmars.D.bugs - [Issue 8913] New: Wrong code in IfStatement condition Expression
- d-bugmail puremagic.com (37/37) Oct 30 2012 http://d.puremagic.com/issues/show_bug.cgi?id=8913
- d-bugmail puremagic.com (9/9) Oct 30 2012 http://d.puremagic.com/issues/show_bug.cgi?id=8913
- d-bugmail puremagic.com (10/10) Dec 18 2012 http://d.puremagic.com/issues/show_bug.cgi?id=8913
- d-bugmail puremagic.com (12/12) Jan 31 2013 http://d.puremagic.com/issues/show_bug.cgi?id=8913
- d-bugmail puremagic.com (9/9) Jan 31 2013 http://d.puremagic.com/issues/show_bug.cgi?id=8913
http://d.puremagic.com/issues/show_bug.cgi?id=8913 Summary: Wrong code in IfStatement condition Expression Product: D Version: D2 Platform: All OS/Version: All Status: NEW Severity: normal Priority: P2 Component: DMD AssignedTo: nobody puremagic.com ReportedBy: ibuclaw ubuntu.com --- Comment #0 from Iain Buclaw <ibuclaw ubuntu.com> 2012-10-30 06:44:09 PDT --- struct A { char[1] b; } void main() { A c; if (*c.b.ptr) return; return; } The following of type char ==== *c.b.ptr ==== Generates and sends to the backend as type char[1] ==== c.b ==== This is wrong and invalid (non-scalar types cannot be used as boolean types). Regards Iain. -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Oct 30 2012
http://d.puremagic.com/issues/show_bug.cgi?id=8913 --- Comment #1 from Iain Buclaw <ibuclaw ubuntu.com> 2012-10-30 08:17:21 PDT --- This conversion occurs in PtrExp::optimize. *&c.b -> c.b For static array types, would there be a problem doing this instead? *&c.b -> c.b[0] -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Oct 30 2012
http://d.puremagic.com/issues/show_bug.cgi?id=8913 Kenji Hara <k.hara.pg gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords| |pull --- Comment #2 from Kenji Hara <k.hara.pg gmail.com> 2012-12-18 00:29:55 PST --- https://github.com/D-Programming-Language/dmd/pull/1382 -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Dec 18 2012
http://d.puremagic.com/issues/show_bug.cgi?id=8913 --- Comment #3 from github-bugzilla puremagic.com 2013-01-31 04:08:19 PST --- Commits pushed to master at https://github.com/D-Programming-Language/dmd https://github.com/D-Programming-Language/dmd/commit/57f6bdcc3ec10dfc9f7081e7b781d4799e45317f fix Issue 8913 - Wrong code in IfStatement condition Expression Type cast from `e : T[n]` to `T*` should generate `&e[0]`, not `&e`. https://github.com/D-Programming-Language/dmd/commit/62818b3863a14ccc828c1d3623db038170a8c129 Merge pull request #1382 from 9rnsr/fix8913 Issue 8913 - Wrong code in IfStatement condition Expression -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Jan 31 2013
http://d.puremagic.com/issues/show_bug.cgi?id=8913 Kenji Hara <k.hara.pg gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Resolution| |FIXED -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Jan 31 2013