Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / fpc-pascal / 2016-02

Bug in FPC 3.0?

5 messages · 3 people · –

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Serguei TARASSOV

Hello,

UniDAC doesn't compile with Lazarus 1.6/FPC 3.0.
The case may be reproduced on following example.

program Project1;
{$MODE DELPHI}
uses
  SysUtils, Classes, DB;
var
  F: TField;
  FieldDef: TFieldDef;
begin
  with F do
    FieldDef := FieldDefs.AddFieldDef;
    //      ^^error here
end.

Free Pascal Compiler version 3.0.0 [2016/02/14] for i386 Copyright (c) 1993-2015 by Florian Klaempfl and others (1002) Target OS: Win32 for i386
(3104) Compiling C:\Users\serge\AppData\Local\Temp\project1.lpr project1.lpr(13,13) Error: (3059) No member is provided to access property project1.lpr(13,16) Error: (5000) Identifier not found "FieldDefs" project1.lpr(16) Fatal: (10026) There were 2 errors compiling module, stopping
Fatal: (1018) Compilation aborted
Error: C:\lazarus\fpc\3.0.0\bin\i386-win32\ppc386.exe returned an error exitcode

-----

Regards, Serguei -- View this message in context: http://free-pascal-general.1045716.n5.nabble.com/Bug-in-FPC-3-0-tp5724260.html Sent from the Free Pascal - General mailing list .
Michael Van Canneyt
to Serguei TARASSOV
Serguei TARASSOV wrote
Hello, UniDAC doesn't compile with Lazarus 1.6/FPC 3.0. The case may be reproduced on following example.

To my knowledge, this has never worked.

Michael.

Show quoted text 42 lines
program Project1; {$MODE DELPHI} uses SysUtils, Classes, DB; var F: TField; FieldDef: TFieldDef; begin with F do FieldDef := FieldDefs.AddFieldDef; // ^^error here end. Free Pascal Compiler version 3.0.0 [2016/02/14] for i386 Copyright (c) 1993-2015 by Florian Klaempfl and others (1002) Target OS: Win32 for i386 (3104) Compiling C:\Users\serge\AppData\Local\Temp\project1.lpr project1.lpr(13,13) Error: (3059) No member is provided to access property project1.lpr(13,16) Error: (5000) Identifier not found "FieldDefs" project1.lpr(16) Fatal: (10026) There were 2 errors compiling module, stopping Fatal: (1018) Compilation aborted Error: C:\lazarus\fpc\3.0.0\bin\i386-win32\ppc386.exe returned an error exitcode ----- -- Regards, Serguei -- View this message in context: http://free-pascal-general.1045716.n5.nabble.com/Bug-in-FPC-3-0-tp5724260.html Sent from the Free Pascal - General mailing list . _______________________________________________ fpc-pascal maillist - http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal
Serguei TARASSOV
to Michael Van Canneyt

Michael Van Canneyt wrote

Show quoted text 10 lines
On Mon, 22 Feb 2016, Serguei TARASSOV wrote: > Hello, > > UniDAC doesn't compile with Lazarus 1.6/FPC 3.0. > The case may be reproduced on following example. To my knowledge, this has never worked. Michael.

History log is below :)

UniDAC 6.1 compiles OK with FPC 2.6.4
But the same sources of UniDAC 6.1 doesn't compile with FPC 3.0 Upgrading, but UniDAC 6.2 doesn't compile with FPC 3.0 too

So I will see tomorrow UniDAC 6.2 with FPC 2.6.4 to provide more info.

-----

Regards, Serguei -- View this message in context: http://free-pascal-general.1045716.n5.nabble.com/Bug-in-FPC-3-0-tp5724260p5724264.html Sent from the Free Pascal - General mailing list .
Michael Van Canneyt
to Serguei TARASSOV
Serguei TARASSOV wrote 13 lines
Michael Van Canneyt wrote > On Mon, 22 Feb 2016, Serguei TARASSOV wrote: > >> Hello, >> >> UniDAC doesn't compile with Lazarus 1.6/FPC 3.0. >> The case may be reproduced on following example. > > To my knowledge, this has never worked. > > Michael. History log is below :)

Well, the compiler is on my side:

home: >ppcx64-2.6 td.pp
td.pp(13,34) Error: Identifier not found "FieldDefs"
td.pp(16,16) Fatal: There were 1 errors compiling module, stopping
Fatal: Compilation aborted
home: >ppcx64-2.6.4 td.pp
td.pp(13,34) Error: Identifier not found "FieldDefs"
td.pp(16,16) Fatal: There were 1 errors compiling module, stopping
Fatal: Compilation aborted

I suspect some refactoring in UniDAC is the cause of your problem. A "with" gone wrong ?

Michael.

LacaK
to Serguei TARASSOV: UniDAC doesn't compile with Lazarus 1.6/FPC 3.0. The case may be reproduced on following…

Error: (3059) No member is provided to access property

is because TField.FieldDef is defined like: Property FieldDef : TFieldDef Read FFieldDef;
so there is no write method from begining (2 years ago rev. 26776).

Error: (5000) Identifier not found "FieldDefs"

FieldDefs is property of TDataSet, not TField so it can not work in your example
(also Delphi has FieldDefs as property of TDataSet)

-Laco.

Show quoted text 46 lines
Hello, UniDAC doesn't compile with Lazarus 1.6/FPC 3.0. The case may be reproduced on following example. program Project1; {$MODE DELPHI} uses SysUtils, Classes, DB; var F: TField; FieldDef: TFieldDef; begin with F do FieldDef := FieldDefs.AddFieldDef; // ^^error here end. Free Pascal Compiler version 3.0.0 [2016/02/14] for i386 Copyright (c) 1993-2015 by Florian Klaempfl and others (1002) Target OS: Win32 for i386 (3104) Compiling C:\Users\serge\AppData\Local\Temp\project1.lpr project1.lpr(13,13) Error: (3059) No member is provided to access property project1.lpr(13,16) Error: (5000) Identifier not found "FieldDefs" project1.lpr(16) Fatal: (10026) There were 2 errors compiling module, stopping Fatal: (1018) Compilation aborted Error: C:\lazarus\fpc\3.0.0\bin\i386-win32\ppc386.exe returned an error exitcode ----- -- Regards, Serguei -- View this message in context: http://free-pascal-general.1045716.n5.nabble.com/Bug-in-FPC-3-0-tp5724260.html Sent from the Free Pascal - General mailing list . _______________________________________________ fpc-pascal maillist - http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal