[Lazarus] JEDI code formatting

Guionardo Furlan guionardo at gmail.com
Tue Feb 16 14:51:03 CET 2010


Sure. I've created a new form to demonstrate:

unit Unit1;

{$mode objfpc}{$H+}

interface

uses
 Classes, SysUtils, FileUtil, LResources, Forms, Controls, Graphics,
Dialogs,
 StdCtrls;

type

 { TForm1 }

 TForm1 = class(TForm)
   Button1: TButton;
   procedure Button1Click(Sender: TObject);
 private
   { private declarations }
 public
   { public declarations }
 end;

var
 Form1: TForm1;

operator ** (b1: byte; b2: byte): integer;

implementation

operator**(b1: byte; b2: byte): integer;
var i : Integer;
begin
  Result:=1;
  for i:=1 to b2 do
    Result:=Result*b1;
end;

{ TForm1 }

procedure TForm1.Button1Click(Sender: TObject);
var
 i:      integer;
 b1, b2: byte;
begin
 b1 := 10;
 b2 := 3;
 i  := b1 ** b2;
 ShowMessage(IntToStr(i));
end;

initialization
 {$I unit1.lrs}

end.

The code is OK, and compiles 100%.

When I command Ctrl-D, I get this from JCF:

http://picasaweb.google.com/lh/photo/_ixt2_gM792PLJ9-ISZ4uw?feat=directlink
[image: jcf.png]

2010/2/15 Paul Ishenin <ip at kmiac.ru>:
> 16.02.2010 3:02, Guionardo Furlan wrote:
>>
>> Well, I see another problem:
>>
>> jcf doesn't recognize operator overloading.
>
> Actually, this was implemented. Can you give an example of code which is
not
> recognized?
>
> Best regards,
> Paul Ishenin.
>
>
> --
> _______________________________________________
> Lazarus mailing list
> Lazarus at lists.lazarus.freepascal.org
> http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
>



-- 
Timeo hominem unius libri
Cogito ergo sum - Carpe diem

[]s
Guionardo Furlan
http://guionardo.blogspot.com
http://www.guionardofurlan.com.br
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lazarus-ide.org/pipermail/lazarus/attachments/20100216/3f6b97ca/attachment-0004.html>


More information about the Lazarus mailing list