Просмотр исходного кода

Ensure that legacy code does not unnecessarily interfere with ARC.

rtl/inc/objpas.inc, TObject:
  * Free: don't call Destroy if the class is reference counted (there might be references left)

git-svn-id: branches/svenbarth/arc@28912 -
svenbarth 10 лет назад
Родитель
Сommit
70e2785dbd
1 измененных файлов с 1 добавлено и 1 удалено
  1. 1 1
      rtl/inc/objpas.inc

+ 1 - 1
rtl/inc/objpas.inc

@@ -338,7 +338,7 @@
 
         begin
            // the call via self avoids a warning
-           if self<>nil then
+           if (self<>nil) and not ARCIsRefCounted then
              self.destroy;
         end;