record and class helpers fail to compile
Original Reporter info from Mantis: sysrpl
-
Reporter name: Anthony Walter
Original Reporter info from Mantis: sysrpl
- Reporter name: Anthony Walter
Description:
When bringing in the LCL both record and class helpers fail to compile with the error message...
Error: identifier idents no member "{Method Name|Property Name}"
Steps to reproduce:
Create a new application with a form and paste code like this:
unit Main;
{$mode delphi}
interface
uses
Classes, SysUtils, FileUtil, Forms, Controls, Graphics, Dialogs, StdCtrls;
{ TForm1 }
type
TPointHelper = record helper for TPoint
procedure Reset;
end;
TForm1 = class(TForm)
Button1: TButton;
procedure Button1Click(Sender: TObject);
private
{ private declarations }
public
{ public declarations }
end;
var
Form1: TForm1;
implementation
{$R *.lfm}
{ TPointHelper }
procedure TPointHelper.Reset;
begin
X := 0;
Y := 0;
end;
{ TForm1 }
procedure TForm1.Button1Click(Sender: TObject);
var
P: TPoint;
begin
P.X := Left;
P.Y := Top;
// main.pas(49,5) Error: identifier idents no member "Reset"
P.Reset;
Left := P.X;
Top := P.Y;
end;
end.
Mantis conversion info:
- Mantis ID: 25210
- OS: Ubuntu
- OS Build: 13.10 64bit
- Build: trunk
- Platform: linux x86_64
- Version: 2.7.1
- Fixed in version: 3.0.0
- Fixed in revision: 25834 (#d91d4afb)
- Monitored by: » Necem (Necem), » kazalex (Kazantsev Alexey), » tangentstorm (michal wallace)