Mail Archives: djgpp/1997/02/20/05:29:17
Luke Lee (comforth AT ms2 DOT hinet DOT net) wrote:
> Does any one know how to write a function with pascal calling
> convention ?
void foo() __attribute__ ((stdcall));
This means that the called function cleans the stack, not the caller.
But I think it does not reverse the order of arguments. See also node
"Function Attributes" of gcc.info.
> Besides, anyone knows how GNU pascal lay its parameter(s) ?
Like GNU C. Caller cleans the stack. Can be changed with
Procedure Foo; attribute ( stdcall );
(* I personally find those double parentheses very funny. Has anybody
an idea why they are doubled? :*)
Hope this helps,
Peter
Dipl.-Phys. Peter Gerwinski, Essen, Germany, free physicist and programmer
peter DOT gerwinski AT uni-essen DOT de - http://home.pages.de/~peter.gerwinski/ [970201]
maintainer GNU Pascal - http://home.pages.de/~gnu-pascal/ [970125]
- Raw text -