[fpc-pascal] Compiler 240

Jichao Yang jcyangzh at gmail.com
Tue Jan 19 16:04:21 CET 2010


Strangely,my 240 compiler do compile your sample code.

My enviroment:windows xp + fpc v2.4.0 + x86.

On Tue, Jan 19, 2010 at 8:08 PM, Carsten Bager <carsten at beas.dk> wrote:

>
> I have a problem with the new 240 compiler.
> I get errors when calling functions in the sysutils unit.
> I have tested the 251 compiler, and it was exactly the same.
> I am normally using the 224 compiler, and it works fine.
>
> Anybody have a hint.
>
> Carsten
>
>
> Example:
>
> program hw1;
> uses
>  sysutils;
>
> Type
>   Datetime_typ=Packed record
>      year,month,day,hour,min,sec,sec100,dayOfWeek:word;
>   end;
> var dt:dateTime_typ;
> Begin
>  WriteLn('Test');
>  decodeTime(Time,dt.hour,dt.min,dt.sec,dt.sec100);
> End.
>
> ------------------------------------------------------
> This program gives  the following output.
> ------------------------------------------------------
>
> / # ./hw1
> Test
> An unhandled exception occurred at $BEAD2EE4 :
> EAccessViolation : Access violation
>  $BEAD2EE4
>
> Heap dump by heaptrc unit
> 10 memory blocks allocated : 853/888
> 8 memory blocks freed     : 817/848
> 2 unfreed memory blocks : 36
> True heap size : 393216
> True free heap : 393024
> Should be : 393048
> Call trace for block $400501E0 size 24
>  $0000E1EC
>  $0000EEFC
>  $000080CC
> Call trace for block $40050180 size 12
>  $0001BB04
>  $0000EEFC
>  $000080CC
> / #
>
> --------------------------------
> Compile info
> --------------------------------
> +---------------------------------+
> | CFG file ver. 1.00 d. 19/9-2006 |
> +---------------------------------+
> +---------------------------------+
> | Cross compiling for ARM 9 Linux |
> +---------------------------------+
> +--------------------------------------+
> |   Compiling with Runetime check !!   |
> |   Stack checking / Range checking    |
> | Check overflow of integer operations |
> +--------------------------------------+
> +--------------+
> | Standard lib |
> +--------------+
> Hint: End of reading config file /etc/fpc.cfg
> Free Pascal Compiler version 2.4.0 [2010/01/19] for arm
> Copyright (c) 1993-2009 by Florian Klaempfl
> Target OS: Linux for ARM
> Compiling hw1.pp
> Assembling hw1
> Linking hw1
> 16 lines compiled, 0.3 sec
> 1 hint(s) issued
>
> _______________________________________________
> fpc-pascal maillist  -  fpc-pascal at lists.freepascal.org
> http://lists.freepascal.org/mailman/listinfo/fpc-pascal
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freepascal.org/pipermail/fpc-pascal/attachments/20100119/4f2f2134/attachment.html>


More information about the fpc-pascal mailing list