On 02/08/2014 10:41, FreeMan wrote:
   Tmy_Form = class(TForm)
   private
     { private declarations }
      v1:integer;
      v2:string;
   public
     { public declarations }
     function exmple(v1:integer;v2:string):boolean;
   end;

when compile:

xx.pas(8,21) Error: Duplicate identifier "v1"
xx.pas(8,32) Error: Duplicate identifier "v2"

first definition main class's variable, compiler error in function
parameter "Duplicate identifier" is it normal or bug?

It is a feature of {$mode objfpc}, not a bug.
If you don't like the feature, use {$mode delphi} which allows such duplicate identifiers (and some other Delphi sloppiness).


--
_______________________________________________
Lazarus mailing list
[email protected]
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus

Reply via email to