digitalmars.D.bugs - Incorrect "delete aa[key] deprecated, use aa.remove(key)" error for linear array.
- Jay (11/11) Jul 04 2005 struct Box { int w, h, d; }
- Jarrett Billingsley (5/16) Jul 05 2005 I think this is just in for a while, so that old code that uses the "del...
- Walter (3/6) Jul 05 2005 Are you using DMD 0.127? It works fine when I try it.
- Jay (5/14) Jul 05 2005 I was using gdc-0.14 which is indicated to be updated to DMD 0.127. I te...
- Walter (5/17) Jul 07 2005 tested
- =?ISO-8859-1?Q?Anders_F_Bj=F6rklund?= (6/8) Jul 07 2005 Or you can use the D.gnu newsgroup, where we discuss other GDC things ?
struct Box { int w, h, d; } int main() { Box*[10] boxes; boxes[0] = new Box; delete boxes[0]; return 0; } The compiler mistakes the linear array in the above program for an associative array, and exits with the following message: bug.d:6: delete aa[key] deprecated, use aa.remove(key)
Jul 04 2005
"Jay" <Jay_member pathlink.com> wrote in message news:dacrtc$26ik$1 digitaldaemon.com...struct Box { int w, h, d; } int main() { Box*[10] boxes; boxes[0] = new Box; delete boxes[0]; return 0; } The compiler mistakes the linear array in the above program for an associative array, and exits with the following message: bug.d:6: delete aa[key] deprecated, use aa.remove(key)I think this is just in for a while, so that old code that uses the "delete" syntax for AAs can be updated to the new syntax. Though it would make sense if the compiler would only issue the deprecated error for AA types..
Jul 05 2005
"Jay" <Jay_member pathlink.com> wrote in message news:dacrtc$26ik$1 digitaldaemon.com...The compiler mistakes the linear array in the above program for an associative array, and exits with the following message: bug.d:6: delete aa[key] deprecated, use aa.remove(key)Are you using DMD 0.127? It works fine when I try it.
Jul 05 2005
Walter wrote:"Jay" <Jay_member pathlink.com> wrote in message news:dacrtc$26ik$1 digitaldaemon.com...I was using gdc-0.14 which is indicated to be updated to DMD 0.127. I tested with DMD 0.127 and it works for me too. I apologize for the false alarm; I'll make sure to check against the latest DMD compiler before filing a report from now on.The compiler mistakes the linear array in the above program for an associative array, and exits with the following message: bug.d:6: delete aa[key] deprecated, use aa.remove(key)Are you using DMD 0.127? It works fine when I try it.
Jul 05 2005
"Jay" <Jay_member pathlink.com> wrote in message news:dafkmd$1dg3$1 digitaldaemon.com...tested"Jay" <Jay_member pathlink.com> wrote in message news:dacrtc$26ik$1 digitaldaemon.com...I was using gdc-0.14 which is indicated to be updated to DMD 0.127. IThe compiler mistakes the linear array in the above program for an associative array, and exits with the following message: bug.d:6: delete aa[key] deprecated, use aa.remove(key)Are you using DMD 0.127? It works fine when I try it.with DMD 0.127 and it works for me too. I apologize for the false alarm; I'll make sure to check against the latest DMD compiler before filing a report from now on.No problem, but may I suggest that if it's a GDC specific problem that there be a "GDC" in the subject? That'll also help David (who maintains GDC).
Jul 07 2005
Walter wrote:No problem, but may I suggest that if it's a GDC specific problem that there be a "GDC" in the subject? That'll also help David (who maintains GDC).Or you can use the D.gnu newsgroup, where we discuss other GDC things ? Sometimes the GDC bugs also affect DMD (since they share the same front-end code), so posting them here might help both compilers... But do state your compiler (with version) and your platform (ditto) --anders
Jul 07 2005