[fpc-pascal] Interface section overload procedures are all public

Rainer Stratmann rainerstratmann at t-online.de
Sun Jan 23 18:12:08 CET 2022


// making only one procedure bugtest public in the interface section
// makes all other bugtest procedures public as well!
// Lazarus 2.0.0+dfsg-2
// FPC-Version: 3.0.4
// OS: Linux Debian 32 Bit

unit test;

interface

procedure bugtest( p1 : longint );

implementation

procedure bugtest( p1 : longint );
begin
end;

procedure bugtest( p1 , p2 : longint );
begin
end;

procedure bugtest( p1 , p2 , p3 : longint );
begin
end;

begin
end. 


// Somewhere in the main program
 bugtest( 1 );
 bugtest( 1 , 2 );
 bugtest( 1 , 2 , 3 );





More information about the fpc-pascal mailing list