From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 5684 invoked by alias); 4 Feb 2020 23:24:53 -0000 Mailing-List: contact gcc-help-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-help-owner@gcc.gnu.org Received: (qmail 5539 invoked by uid 89); 4 Feb 2020 23:24:52 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=2.3 required=5.0 tests=AWL,BAYES_50,FORGED_MUA_MOZILLA,KAM_NUMSUBJECT,SPF_PASS autolearn=no version=3.3.1 spammy=H*f:sk:CAH6eHd, __fastcall__, Edward, Diener X-HELO: ciao.gmane.io Received: from ciao.gmane.io (HELO ciao.gmane.io) (159.69.161.202) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 04 Feb 2020 23:24:49 +0000 Received: from list by ciao.gmane.io with local (Exim 4.92) (envelope-from ) id 1iz7Yg-000HY1-Sc for gcc-help@gcc.gnu.org; Wed, 05 Feb 2020 00:24:42 +0100 To: gcc-help@gcc.gnu.org From: Edward Diener Subject: Re: Function attributes and x32, x64 Date: Tue, 04 Feb 2020 23:24:00 -0000 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:68.0) Gecko/20100101 Thunderbird/68.4.2 In-Reply-To: X-IsSubscribed: yes X-SW-Source: 2020-02/txt/msg00034.txt.bz2 On 2/4/2020 12:41 PM, Jonathan Wakely wrote: > On Sat, 1 Feb 2020 at 11:07, Edward Diener > wrote: >> >> 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 > > Aside: Please don't misuse the term "x32" (which means something > different here), and avoid the dumb "x64" term (which is a > Windows-ism). > Do you prefer I should rather say x86-32 and x86-64 for 32-bit and 64-bit compilation respectively ? That is OK with me. But the issue of the error messages when using x86-32 compilation is still baffling to me.