extern "C" bug??

Dale Mellor Dale.Mellor@newcastle.ac.uk
Thu Oct 22 03:28:00 GMT 1998


I am using egcs-1.0.3 after upgrading from gcc-2.7.2, and am writing
C++ code that needs to link to a FORTRAN program. It has stopped working
and it turns out that the cure is to convert C++ functions with return
types of float into ones with types of double.

I thought that specifying c linkage, i.e. 'extern "C" real foo() {...}' was
supposed to automatically promote real return values (and function
arguments for that matter) into double precision. I presume it worked
before for this reason, therefore is this a bug in egcs?


                                                                   Dale
 
  e-mail : ndm@netcomuk.co.uk      snail : DM Bespoke Computer Solutions Ltd
   phone : +44 91 420 9002                      114 Wellington Road
     fax :   As above ('phone first)             Dunston
     www : http://www.netcomuk.co.uk/~ndm         GATESHEAD
             (under development)                   Tyne and Wear
                                                    NE11 9HE
                                                     U.K.





More information about the Gcc-bugs mailing list