diff qt/core/QList.d @ 330:115130499d78 signals

fix a const violation spotted by a newer dmd, thanks Rainer
author eldar1@eldar1-laptop
date Sat, 16 Jan 2010 12:20:50 +0000
parents 7a3c43424dca
children 5896535a03cd
line wrap: on
line diff
--- a/qt/core/QList.d	Sun Jan 10 11:16:49 2010 +0000
+++ b/qt/core/QList.d	Sat Jan 16 12:20:50 2010 +0000
@@ -405,10 +405,11 @@
     {
 //        writeln("QList opAssign");
         if (d != l.d) {
-            l.d.ref_.increment();
+            QListData.Data* nd = cast(QListData.Data*)l.d;
+            nd.ref_.increment();
             if (!d.ref_.decrement())
                 free(d);
-            d = cast(QListData.Data*)l.d;
+            d = nd;
             if (!d.sharable)
                 detach_helper();
         }
@@ -622,4 +623,4 @@
 extern(C) void qtd_create_QList(void *nativeId);
 extern(C) void qtd_create_QList_double(void *nativeId);
 
-extern(C) void qtd_create_QList_QObject(void *nativeId);
\ No newline at end of file
+extern(C) void qtd_create_QList_QObject(void *nativeId);