Browse Source

* get rid of calls to aligntoptr by using methods provided by TClassData and TPropInfo

git-svn-id: trunk@37423 -
svenbarth 7 years ago
parent
commit
89645633a9
1 changed files with 2 additions and 2 deletions
  1. 2 2
      packages/rtl-objpas/src/inc/rtti.pp

+ 2 - 2
packages/rtl-objpas/src/inc/rtti.pp

@@ -1692,7 +1692,7 @@ begin
 
         // published properties count for this object
         // skip the attribute-info if available
-        PPD := aligntoptr(PPropData(pointer(@TD^.UnitName)+PByte(@TD^.UnitName)^+1));
+        PPD := PClassData(TD)^.PropertyTable;
         Count:=PPD^.PropCount;
         // Now point TP to first propinfo record.
         TP:=PPropInfo(@PPD^.PropList);
@@ -1711,7 +1711,7 @@ begin
 
             // Point to TP next propinfo record.
             // Located at Name[Length(Name)+1] !
-            TP:=aligntoptr(PPropInfo(pointer(@TP^.Name)+PByte(@TP^.Name)^+1));
+            TP:=TP^.Next;
             Dec(Count);
           end;
         TypeInfo:=TD^.Parentinfo;