[fpc-devel]1.1 default parameters

Peter Vreman peter at freepascal.org
Sat Jul 5 20:36:42 CEST 2003


> Hi there,
>
> I have seen 1.1 understanding default parameters for a very long time, now
> the compiler ignores them and demands for explicit value to be passed in
> any case.
>
> procedure test(a: integer = 0);
>
> test(1);
> test();  //compiler will fail
>
> Am I missing something? Could that be that I need a command line switch to
> turn them on? OR I suggest propery they are just not implemented at the
> time? I understand this is because the parameter handling is in major
> development? Any projection on how soon it can be back and working? Any
> help needed?

The next program compiles fine with both -Sd and -S2 command line options.

procedure p(a:integer=0);
begin
end;

begin
  p;
  p();
end.






More information about the fpc-devel mailing list