[fpc-devel] type question

Ivo Steinmann ivo_steinmann at gmx.net
Sat Oct 14 17:29:40 CEST 2006


Marc Weustink wrote:
> program TypeTest;
> {$mode objfpc}{$h+}
>
> type
>   TMyA = type String;
>   TMyB = type String;
>
> var
>   A: TMyA;
>   B: TMyB;
>   S: String;
>
> begin
>   S := 'Some value';
>   A := S;
>   B := S;
>
>   S := A;
>   S := B;
>
>   A := B;
>   B := A;
> end.
>
>   
Well, assign works, but if you use them as var Parameters it works not! 
It's also nice if you have got overloaded functions.

-Ivo



More information about the fpc-devel mailing list