[fpc-devel] QueryInterface on linux/i386 - adding 'in' parameter type?

Jonas Maebe jonas.maebe at elis.ugent.be
Sun Aug 29 16:18:41 CEST 2010


On 29 Aug 2010, at 16:10, Michael Van Canneyt wrote:

> What does stdcall calling convention currently do on non-windows platforms ?

The same as on Windows.

> I think that having to write
>  {$ifdef windows}const{$else}constref{$endif} myarg: mytype
> for possibly thousands of arguments in an interface description is simply not
> an option.

That would not be necessary:
a) constref would be correct both for Windows and non-Windows
b) I'm not aware of a single routine that uses stdcall on non-Windows, other than the AddRef and ReleaseRef routines mentioned at the start of this discussion

If you want to apply a custom calling convention to an entire file, that is also already supported using {$calling xxx} (which I'm not very fond of either).


Jonas


More information about the fpc-devel mailing list