pascalabcnet/TestSuite/opImplicit.pas

9 lines
162 B
ObjectPascal
Raw Normal View History

2020-08-01 16:04:54 +03:00
type
t1<T> = class
static function operator implicit(o: T): t1<T> := new t1<T>;
end;
begin
var a: t1<string> := 'abcde';
Assert(a <> nil);
end.