Browse Source

* apparently, Darwin/x86-64 also uses an opaque ISA pointer on OS X 10.11
-> assume it is always the case for non-fragile ABI platforms
(mantis #29667)

git-svn-id: trunk@33112 -

Jonas Maebe 9 năm trước cách đây
mục cha
commit
356a5aff05
1 tập tin đã thay đổi với 4 bổ sung3 xóa
  1. 4 3
      compiler/nmem.pas

+ 4 - 3
compiler/nmem.pas

@@ -252,10 +252,11 @@ implementation
              if (is_objc_class_or_protocol(left.resultdef) or
                  is_objcclassref(left.resultdef)) then
                begin
-                 if target_info.system=system_aarch64_darwin then
+                 { on non-fragile ABI platforms, the ISA pointer may be opaque
+                   and we must call Object_getClass to obtain the real ISA
+                   pointer }
+                 if target_info.system in systems_objc_nfabi then
                    begin
-                     { on Darwin/AArch64, the isa field is opaque and we must
-                       call Object_getClass to obtain the actual ISA pointer }
                      result:=ccallnode.createinternfromunit('OBJC','OBJECT_GETCLASS',ccallparanode.create(left,nil));
                      inserttypeconv_explicit(result,resultdef);
                    end