public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug other/12782] New: ffi.h #defines ffi_type_[us]long wrong on 32bit arches
@ 2003-10-27  0:47 a dot rottmann at gmx dot at
  2003-10-27  0:55 ` [Bug other/12782] " a dot rottmann at gmx dot at
                   ` (5 more replies)
  0 siblings, 6 replies; 7+ messages in thread
From: a dot rottmann at gmx dot at @ 2003-10-27  0:47 UTC (permalink / raw)
  To: gcc-bugs

PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=12782

           Summary: ffi.h #defines ffi_type_[us]long wrong on 32bit arches
           Product: gcc
           Version: 3.3.2
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: other
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: a dot rottmann at gmx dot at
                CC: gcc-bugs at gcc dot gnu dot org

The way ffi.h #defines the ffi_type_XX equivalents to the standard C
types seems bad - they are mixed along with the #defines of the
fixed-bit types (e.g. UINT32), but the two issues are orthogonal. 

This results in ffi_type_ulong, for instance, being #defined to ffi_type_uint64
on (at least) x86, as the following test program indicates:

#include <stdio.h>
#include <ffi.h>

int main ()
{
  printf ("&ffi_type_ulong: %p &ffi_type_uint64: %p\n", 
          &ffi_type_ulong, &ffi_type_uint64);
}

This results in the following output on my Athlon (no, no Athlon64 yet ;-))

&ffi_type_ulong: 0x8049738 &ffi_type_uint64: 0x8049738


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2003-12-19  9:56 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-10-27  0:47 [Bug other/12782] New: ffi.h #defines ffi_type_[us]long wrong on 32bit arches a dot rottmann at gmx dot at
2003-10-27  0:55 ` [Bug other/12782] " a dot rottmann at gmx dot at
2003-10-27  0:58 ` pinskia at gcc dot gnu dot org
2003-10-27  1:46 ` pinskia at gcc dot gnu dot org
2003-10-27  9:50 ` a dot rottmann at gmx dot at
2003-10-31  6:17 ` green at redhat dot com
2003-12-19  9:57 ` pinskia at gcc dot gnu dot org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).