[fpc-devel] function overload ?
Gennadiy Poryev
core at barvinok.net
Mon Feb 3 07:54:01 CET 2014
Hi!
I had a dream :)
Wouldn't it be nice if a function overload took care not only of formal
parameter list (per docs) but also of result type? So the following may work
function My(const a : Integer) : AnsiString; overload;
function My(const a : Integer) : WideString; overload;
by substitution of the function depending on the expected type of the
expression it is being called from?
More information about the fpc-devel
mailing list