------- Additional Comments From p dot obry at wanadoo dot fr 2005-03-19 13:08 ------- (In reply to comment #2) > The IS_TARGET_PE_COFF hack works on 3.4.x bit won't on trunk. > > Here is a cleaner patch against trunk that replaces the preprocessor tests > with runtime tests. I have tested with nativr mingw bootstrap but not with > cross-compile build.
The first part of the patch is not correct. On UNIX machines, we want the Stdcall calling convention applied to a function or procedure be equivalent to a C calling convention. The first part of the pacth break that. > Index: ada/decl.c > =================================================================== > RCS file: /cvs/gcc/gcc/gcc/ada/decl.c,v > retrieving revision 1.65 > diff -c -3 -p -r1.65 decl.c > *** ada/decl.c 10 Feb 2005 13:53:20 -0000 1.65 > --- ada/decl.c 18 Mar 2005 04:15:54 -0000 > *************** gnat_to_gnu_entity (Entity_Id gnat_entit > *** 3642,3648 **** > if (list_length (gnu_return_list) == 1) > gnu_return_type = TREE_TYPE (TREE_PURPOSE (gnu_return_list)); > > - #ifdef _WIN32 > if (Convention (gnat_entity) == Convention_Stdcall) > { > struct attrib *attr > --- 3642,3647 ---- The other part looks fine to me. Pascal. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20515