[fpc-devel] Illegal type conversion: "<enumeration type>" to "TObject"

Florian Klaempfl florian at freepascal.org
Thu Jul 17 13:41:06 CEST 2008


Sean McIlwain schrieb:
> The following code fails to compile in Delphi mode but successfully 
> compiles in objfpc mode:
> 
> type
>  TEnum = (a, b, c);
> var
>  AValue: TEnum;
>  AObject : TObject;
> implementation
> 
> initialization
>  AObject := TObject(AValue);
> 
> 
> 
> Could this be supported in the Delphi mode as well?

Please submit a bug report.



More information about the fpc-devel mailing list