- changed status to resolved
IsNullableType doesn't works for Aliased Nullable types (TNullableString, TNullableInteger and so on)
In the function body, there's an hardcoded prefix for the type name that prevent to use it for nullable aliased types. It works as espected for Nullable<String> but not for TNullableString
function IsNullableType(typeInfo: PTypeInfo): Boolean; const PrefixString = 'Nullable<'; {this is hardcoded} begin Result := Assigned(typeInfo) and (typeInfo.Kind = tkRecord) and StartsText(PrefixString, GetTypeName(typeInfo)); end;
Comments (4)
-
reporter -
reporter Sorry boys, there were something elso that invalidate the test... I redidi the test and with the aliases types it works... more to come.
-
reporter - changed status to invalid
Strange behaviour... now it works. Problebly I did some errors...
-
repo owner As these types are just aliases there is no new type defined. That means at runtime TNullableString is actually the type Nullable<string>.
If you encounter any further problems, feel free to reopen the report.
- Log in to comment