[fpc-pascal] Re: fcl-passrc package question about source file and line number info

Seth Grover sethdgrover at gmail.com
Mon Jul 16 20:26:39 CEST 2012


Michael wrote:
> Please check revision 21909.
> I haven't done much testing, because I didn't get to the test cases for
> statements yet.

Michael, I grabbed what's currently up in the svn trunk under fcl-passrc.

I am getting the source filename and line number information now, so
that's great.

I did notice one problem, though... when FreeAndNil'ing the TPasModule
object returned from ParseSource, I am able to get it to segfault with
a simple example.

I dummied it down into this source file:

==================================================
unit timelib;

interface

implementation

var
  elapsedT   : array [0..999] of int64;
  ic         : longword;

initialization
  for ic := low(elapsedT) to high(elapsedT) do begin
    elapsedT[ic] := 0;
  end;

end.
==================================================

If you run the test_parser program (which I actually had to tweak to
get it to compile) with that little unit as input, you'll get a
segfault when doing the FreeAndNil(M).

I'll let you know if i run into anything else.

Thanks,

-SG

--
This email is fiction. Any resemblance to actual events
or persons living or dead is purely coincidental.

Seth Grover


On Thu, Jul 12, 2012 at 1:38 PM, Seth Grover <sethdgrover at gmail.com> wrote:
>> Oversight, a bug.
>> I am currently working on the parser, I'll look into this.
>> Michael.
>
> Thanks, I appreciate it.
>
> -SG
>
> --
> This email is fiction. Any resemblance to actual events
> or persons living or dead is purely coincidental.
>
> Seth Grover



More information about the fpc-pascal mailing list