Sign in Join

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

Mailing lists / fpc-devel / 2000-09

win32 compiler funny

7 messages · 4 people · –

Reply by email Subscribe to this list Your subscription

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

Lee, John

this w32 program compiles ok with w32 release, but gives error message with latest snapshot...! Why?

<<SIMP.ZIP>>
c:\pas>pas simp
win32/snap(s) c:\ppw\bin\ppc386 (20/09/00 02:07 258560)-- rtl path in .cfg is -FuC:\PPw\RTL\win32
Free Pascal Compiler version 1.1 [2000/09/20] for i386 Copyright (c) 1993-2000 by Florian Klaempfl
Target OS: Win32 for i386
Compiling simp.pp
simp.pp(27,5) Fatal: Syntax error, BEGIN expected but OUT found

c:\pas>pas simp
win32/rel(s) c:\ppwr\bin\ppc386 (10/07/00 15:45 245760)-- rtl path in .cfg is -FuC:\PPwr\RTL\win32
Free Pascal Compiler version 1.00 [2000/07/10] for i386 Copyright (c) 1993-2000 by Florian Klaempfl
Target OS: Win32 for i386
Compiling simp.pp
Linking simp.exe
670 Lines compiled, 2.9 sec

begin 600 SIMP.ZIP
M4$L#!!0````(`/B,-"F#T06+'!(``/,V```'````4TE-4"Y04.T[[6[;N+*_ M;X"\PQ1HCZ68R4JVD^W*5=LT2<\&R+9%TWL*W&X0R!(=*Y$H5:03IT$?];S+ MY9"41,G.WIZ]V!_W(TEM:<@9#F?(^2+[\/2W]\<G<'QR]N'7T^_;6P]/%[OR MZ]\YY?`Y94EQQTE2\.GV5EPP+@"VMT#]Y-'JLJR*F(>^YTUKZ&PYY^FW<+3C M>Z.)^FB:N(@J$27ATXF'/PT\CB0&#?V#\?.V<UPN1;@_]KV??_[9!I:TBA$N ';@7S3XEQZ89QK^>P\>%Z8AZ#4D
MA=`->[V&,M;P9Q8\2X7(:#C:QPF)^Y+"++V*PJBJHOLO_M[>`4KK`HJYHM"@ M;6_=1A5PPGV":B!Q7A(>W9(DY251\DMSV4+5<QIP4:7LRF"OR#V!2OCX,2*5 M2(@@\JV,B43R"2+KS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*87BIU**A^C@ MX>OW];E(,@>FUJ9-J2I/PV6O\GR!?6F:)=_%(=UR@
MS?I<;]96;H-)6UO!\*STY;)])S,%F9U7OU)-WQWOX_9]02P$"%``4 M````"@``!P`````````!`"``````````4TE-4"Y0

`
end

Reply by email

Jonas Maebe
Show quoted text 12 lines
this w32 program compiles ok with w32 release, but gives error message with latest snapshot...! Why? <<SIMP.ZIP>> c:\pas>pas simp win32/snap(s) c:\ppw\bin\ppc386 (20/09/00 02:07 258560)-- rtl path in .cfg is -FuC:\PPw\RTL\win32 Free Pascal Compiler version 1.1 [2000/09/20] for i386 Copyright (c) 1993-2000 by Florian Klaempfl Target OS: Win32 for i386 Compiling simp.pp simp.pp(27,5) Fatal: Syntax error, BEGIN expected but OUT found

'OUT' is apparently some kind of calling convention for which support was added in version 1.1 (and as such, 'out' is now a keyword). I don't know what it's used for.

Jonas

Reply by email

Lee, John

yup, thanks it's ok w/o out - suppose I should've guessed that out had become keyword... Don't remember this being announced - what is it? ... hope it's in new docs. BTW when will we get rel 1.01, with new docs?

Earlier message 27 lines
-----Original Message----- From: Jonas Maebe Sent: 21 September 2000 08:01 To: Subject: Re: [fpc-devel]win32 compiler funny >this w32 program compiles ok with w32 release, but gives error message with >latest snapshot...! Why? > > <<SIMP.ZIP>> >c:\pas>pas simp >win32/snap(s) c:\ppw\bin\ppc386 (20/09/00 02:07 258560)-- >rtl path in .cfg is -FuC:\PPw\RTL\win32 >Free Pascal Compiler version 1.1 [2000/09/20] for i386 >Copyright (c) 1993-2000 by Florian Klaempfl >Target OS: Win32 for i386 >Compiling simp.pp >simp.pp(27,5) Fatal: Syntax error, BEGIN expected but OUT found 'OUT' is apparently some kind of calling convention for which support was added in version 1.1 (and as such, 'out' is now a keyword). I don't know what it's used for. Jonas

Reply by email

Jonas Maebe
yup, thanks it's ok w/o out - suppose I should've guessed that out had become keyword... Don't remember this being announced - what is it? ... hope it's in new docs. BTW when will we get rel 1.01, with new docs?

I don't know when 1.01 will be released, but I don't think it will include much changed docs. After all, 1.01 won't include this 'out' keyword and most other additions.

Jonas

Reply by email

Florian Klaempfl
to Jonas Maebe: 'OUT' is apparently some kind of calling convention for which support was added in…
Jonas Maebe wrote
'OUT' is apparently some kind of calling convention for which support was added in version 1.1 (and as such, 'out' is now a keyword). I don't know what it's used for.

OUT is used for COM support. It uses the same mechanism as VAR but no value is passed when calling the procedure, only the output is important. This has only consequences for ref. counted types as ansistrings and interfaces.

Reply by email

Pápai András
OUT is used for COM support. It uses the same mechanism as VAR but no value is passed when calling the procedure, only the output is important.

How does this work? AFAIK using VAR parameters, the address is passed, not the value.

Andras

Reply by email

Florian Klaempfl
to Pápai András
Pápai András wrote 8 lines
> OUT is used for COM support. It uses the same mechanism as VAR but no > value is passed when calling the procedure, only the output > is important. How does this work? AFAIK using VAR parameters, the address is passed, not the value.

Yes, but you removed the important sentence:
This has only consequences for ref. counted types as ansistrings and interfaces.

This means:

procedure p(out a : ansistring);
  begin
  end;
var
   ga : ansistring;

...

   p(ga);

...

Before calling p, the ref. count of ga is decreased (and if it is zero, the data is disposed). and ga is set to zero/nil.

The same happens for COM interfaces where this is necessary when you request an interface.

For other data types (if they don't contain a ref. counted type) there is _no_ difference to var calling conventions.

Reply by email