@@ -3623,12 +3623,7 @@ class procedure TPyDelphiObject.ExposeFields(AClass: TClass;
3623
3623
Continue;
3624
3624
3625
3625
// Skip if the type cannot be handled
3626
- if not (LRttiField.FieldType.TypeKind in
3627
- [tkInteger, tkChar, tkFloat, tkString, tkWChar, tkLString, tkWString,
3628
- tkUString, tkInt64, tkVariant, tkEnumeration, tkSet, tkArray,
3629
- tkDynArray, tkClass, tkClassRef,
3630
- tkRecord{ $IFDEF MANAGED_RECORD} , tkMRecord{ $ENDIF} ])
3631
- then
3626
+ if LRttiField.FieldType.TypeKind in [tkUnknown, tkMethod, tkProcedure] then
3632
3627
Continue;
3633
3628
3634
3629
AddedFields := AddedFields + [LRttiField.Name ];
@@ -3705,13 +3700,8 @@ class procedure TPyDelphiObject.ExposeProperties(AClass: TClass;
3705
3700
if not LRttiProperty.IsReadable then
3706
3701
Continue;
3707
3702
3708
- // Skip if the type cannot be handled (as with fields + tkMethod)
3709
- if not (LRttiProperty.PropertyType.TypeKind in
3710
- [tkInteger, tkChar, tkFloat, tkString, tkWChar, tkLString, tkWString,
3711
- tkUString, tkInt64, tkVariant, tkEnumeration, tkSet, tkArray,
3712
- tkDynArray, tkClass, tkClassRef, tkMethod,
3713
- tkRecord{ $IFDEF MANAGED_RECORD} , tkMRecord{ $ENDIF} ])
3714
- then
3703
+ // Skip if the type cannot be handled (as with fields - tkMethod)
3704
+ if LRttiProperty.PropertyType.TypeKind in [tkUnknown, tkProcedure] then
3715
3705
Continue;
3716
3706
3717
3707
AddedProperties := AddedProperties + [LRttiProperty.Name ];
0 commit comments