ソースを参照

* correctly handle record, set and array results if no extended parameter information is available

git-svn-id: trunk@40669 -
svenbarth 6 年 前
コミット
9eac2ea852
1 ファイル変更18 行追加0 行削除
  1. 18 0
      packages/rtl-objpas/src/x86_64/invoke.inc

+ 18 - 0
packages/rtl-objpas/src/x86_64/invoke.inc

@@ -100,6 +100,24 @@ begin
       tkInterface,
       tkDynArray:
         Result := True;
+      tkArray: begin
+        td := GetTypeData(aType);
+        Result := not (td^.ArrayData.Size in [1, 2, 4, 8]);
+      end;
+      tkRecord: begin
+        td := GetTypeData(aType);
+        Result := not (td^.RecSize in [1, 2, 4, 8]);
+      end;
+      tkSet: begin
+        td := GetTypeData(aType);
+        case td^.OrdType of
+          otUByte:
+            Result := not (td^.SetSize in [1, 2, 4, 8]);
+          otUWord,
+          otULong:
+            Result := False;
+        end;
+      end;
     end;
   end;
 end;