Re: [fpc-pascal]parameter is 0x0 on callback

2004-06-05 Thread Marc Santhoff
Am Sa, den 05.06.2004 schrieb Peter Vreman um 10:05: > > So i looked in the docs and asked myself: > > > > What are the limits for stack and heap? > > And why does the -Cs switch do nothing on Linux and FreeBSD? > > > > Fact is, the stack is overflowing right at the start and i did not > > notice.

Re: [fpc-pascal]parameter is 0x0 on callback

2004-06-05 Thread Peter Vreman
> So i looked in the docs and asked myself: > > What are the limits for stack and heap? > And why does the -Cs switch do nothing on Linux and FreeBSD? > > Fact is, the stack is overflowing right at the start and i did not > notice. That is part of Linux and FreeBSD in the docs is obsolete. Stackch

Re: [fpc-pascal]parameter is 0x0 on callback

2004-06-04 Thread Marc Santhoff
Am Fr, den 04.06.2004 schrieb Marco van de Voort um 22:54: > > oncemore for the sake of completeness: > > > > The 1.9.2 version of fpc is buggy on FreeBSD. > > > > I get various problems in a method of an object reading its own private > > variables. Some do work, others don't. No scheme of findi

Re: [fpc-pascal]parameter is 0x0 on callback

2004-06-04 Thread Marc Santhoff
Am Fr, den 04.06.2004 schrieb Marc Santhoff um 22:42: > There may be a coincidence with the order of the vars in the VMT (looks > as if the first one is the faulty one), but i cannot say so for sure. Sorry, no VMT for vars, I meant the first one listed in the source (displayed first in the debugg

Re: [fpc-pascal]parameter is 0x0 on callback

2004-06-04 Thread Marco van de Voort
> oncemore for the sake of completeness: > > The 1.9.2 version of fpc is buggy on FreeBSD. > > I get various problems in a method of an object reading its own private > variables. Some do work, others don't. No scheme of finding out which > will. Then it is probably a memory problem. I used 1.9.

Re: [fpc-pascal]parameter is 0x0 on callback

2004-06-04 Thread Marc Santhoff
Am Fr, den 04.06.2004 schrieb Marco van de Voort um 21:45: > > > 1.9.4 reports: > > > > > > main192.pp(25,52) Error: Incompatible type for arg no. 1: Got " > > procedure(TCustomer);CDecl>", expected " > > procedure(TCustomer);Register>" > > > > Ah, I see. I'll change the declaration of the callba

Re: [fpc-pascal]parameter is 0x0 on callback

2004-06-04 Thread Marc Santhoff
Hi again, oncemore for the sake of completeness: The 1.9.2 version of fpc is buggy on FreeBSD. I get various problems in a method of an object reading its own private variables. Some do work, others don't. No scheme of finding out which will. There may be a coincidence with the order of the var

Re: [fpc-pascal]parameter is 0x0 on callback

2004-06-04 Thread Marco van de Voort
> > 1.9.4 reports: > > > > main192.pp(25,52) Error: Incompatible type for arg no. 1: Got " > procedure(TCustomer);CDecl>", expected " > procedure(TCustomer);Register>" > > Ah, I see. I'll change the declaration of the callback proc then. > > I hope the version 1.9.4 is getting into the ports sys

Re: [fpc-pascal]parameter is 0x0 on callback

2004-06-04 Thread Marc Santhoff
Am Fr, den 04.06.2004 schrieb Peter Vreman um 19:25: > > Here it is (as attachment, hopefully the list processor doesn't strip it > > off): > > 1.9.4 reports: > > main192.pp(25,52) Error: Incompatible type for arg no. 1: Got " procedure(TCustomer);CDecl>", expected " procedure(TCustomer);Register

Re: [fpc-pascal]parameter is 0x0 on callback

2004-06-04 Thread Peter Vreman
> Here it is (as attachment, hopefully the list processor doesn't strip it > off): 1.9.4 reports: main192.pp(25,52) Error: Incompatible type for arg no. 1: Got "", expected "" ___ fpc-pascal maillist - [EMAIL PROTECTED] http://lists.freepascal.org/

Re: [fpc-pascal]parameter is 0x0 on callback

2004-06-04 Thread Marc Santhoff
Here it is (as attachment, hopefully the list processor doesn't strip it off): unit browser192; {$define debug} interface uses sysutils, glib, gdk, gtk, unix; const SEP: char = ';'; QT: char = '"'; type TCustomer = class Name: AnsiString;

Re: [fpc-pascal]parameter is 0x0 on callback

2004-06-04 Thread Marc Santhoff
Am Fr, den 04.06.2004 schrieb Peter Vreman um 17:54: > >> Without a full (short) example we can't do anything. > > > > See below, I've tried to cut down the size without loosing to much > > information this time ... > > > >> > And why it worked fine on the 1.0.10 version of fpc? > >> > >> 1.9.2 use

Re: [fpc-pascal]parameter is 0x0 on callback

2004-06-04 Thread Peter Vreman
>> Without a full (short) example we can't do anything. > > See below, I've tried to cut down the size without loosing to much > information this time ... > >> > And why it worked fine on the 1.0.10 version of fpc? >> >> 1.9.2 uses register calling by default. > > I don't get that. Do you say it wo

Re: [fpc-pascal]parameter is 0x0 on callback

2004-06-04 Thread Marc Santhoff
Am Fr, den 04.06.2004 schrieb Peter Vreman um 08:46: [...] > Without a full (short) example we can't do anything. See below, I've tried to cut down the size without loosing to much information this time ... > > And why it worked fine on the 1.0.10 version of fpc? > > 1.9.2 uses register calling

Re: [fpc-pascal]parameter is 0x0 on callback

2004-06-03 Thread Peter Vreman
> Hello, > > I've used the stuff following with fpc 1.0.10 and it worked fine, now > with 1.9.2 the argument is set to zero: > > - a GTK+ 1.2 program) > - a dialog has a pointer to a 'cdecl'ed callback procedure: > > > ... > src := TCustomer(datasrc.Items[selCursor]); > {$ifdef debug} writeln(src.

Re: [fpc-pascal]parameter is 0x0 on callback

2004-06-03 Thread Peter Vreman
> Hi again, > > the problem seems to occur any time I try to access (unit global) > variables in a cdecl-ed procedure or function, too. They are simply > invisible in the debugger. > > What am I doing wrong here? Try the 1.9.4 release, there are fixes in the debuginfo generation __

[fpc-pascal]parameter is 0x0 on callback

2004-06-03 Thread Marc Santhoff
Hi again, the problem seems to occur any time I try to access (unit global) variables in a cdecl-ed procedure or function, too. They are simply invisible in the debugger. What am I doing wrong here? Marc ___ fpc-pascal maillist - [EMAIL PROTECTED

[fpc-pascal]parameter is 0x0 on callback

2004-06-03 Thread Marc Santhoff
Hello, I've used the stuff following with fpc 1.0.10 and it worked fine, now with 1.9.2 the argument is set to zero: - a GTK+ 1.2 program) - a dialog has a pointer to a 'cdecl'ed callback procedure: ... src := TCustomer(datasrc.Items[selCursor]); {$ifdef debug} writeln(src.asCSV); {$endif} { p