VirtualBox

Changeset 40427 in vbox for trunk/include/iprt


Ignore:
Timestamp:
Mar 12, 2012 1:29:07 PM (13 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
76765
Message:

iprt/cdefs: gcc-4.7 fix: Make DECLASM compatible with DECLCALLBACK. gcc-4.7 is a bit over-pedantic because regparm(0) is default on 32-bit hosts. But a function declaration with regparm(0) is not compatible with a declaration without.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/include/iprt/cdefs.h

    r40404 r40427  
    699699# ifdef _MSC_VER
    700700#  define DECLASM(type)          extern "C" type __cdecl
     701# elif defined(__GNUC__) && defined(RT_ARCH_X86)
     702#  define DECLASM(type)          extern "C" type __attribute__((cdecl,regparm(0)))
    701703# else
    702704#  define DECLASM(type)          extern "C" type
     
    705707# ifdef _MSC_VER
    706708#  define DECLASM(type)          type __cdecl
     709# elif defined(__GNUC__) && defined(RT_ARCH_X86)
     710#  define DECLASM(type)          type __attribute__((cdecl,regparm(0)))
    707711# else
    708712#  define DECLASM(type)          type
Note: See TracChangeset for help on using the changeset viewer.

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette