Function attributes and x32, x64

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Given the code:

class cbase;
int main()
    {
    typedef int __attribute__ ((__stdcall__)) (cbase::* atype)();
    typedef int __attribute__ ((__cdecl__)) (cbase::* btype)();
    typedef int __attribute__ ((__fastcall__)) (cbase::* ctype)();
    typedef int __attribute__ ((__thiscall__)) (cbase::* dtype)();
    return 0;
    }


If I compile this for x64 (-m64) in gcc-9.2 I receive no errors or warnings. Yet https://gcc.gnu.org/onlinedocs/gcc/x86-Function-Attributes.html tells me that all four are only for x86-32 targets. Is the documentation wrong, is this a bug in gcc-9.2, or have I missed something ?




[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux