I would like to know if this is possible in Delphi (or if there is a clean path around it):
type TSomething = record X, Y : Integer; end;
GetSomething( x, y ) Returns a record with these values.
... and then you have this function with the TSomething parameter as the parameter, and you want to use it as the default
function Foo( Something : TSomething = GetSomething( 1, 3 );
The compiler spits out an error here, but I'm not sure if it has a way!
Can this be done?
source share