From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.org/gmane.linux.lib.musl.general/9803 Path: news.gmane.org!not-for-mail From: Rich Felker Newsgroups: gmane.linux.lib.musl.general Subject: Re: size_t and int64_t on a new platform Date: Thu, 31 Mar 2016 16:30:04 -0400 Message-ID: <20160331203004.GX21636@brightrain.aerifal.cx> References: <20160331192518.GW21636@brightrain.aerifal.cx> <20160331201012.GR9862@port70.net> Reply-To: musl@lists.openwall.com NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1459456222 20617 80.91.229.3 (31 Mar 2016 20:30:22 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 31 Mar 2016 20:30:22 +0000 (UTC) To: musl@lists.openwall.com Original-X-From: musl-return-9816-gllmg-musl=m.gmane.org@lists.openwall.com Thu Mar 31 22:30:21 2016 Return-path: Envelope-to: gllmg-musl@m.gmane.org Original-Received: from mother.openwall.net ([195.42.179.200]) by plane.gmane.org with smtp (Exim 4.69) (envelope-from ) id 1aljES-0008Bm-07 for gllmg-musl@m.gmane.org; Thu, 31 Mar 2016 22:30:20 +0200 Original-Received: (qmail 11750 invoked by uid 550); 31 Mar 2016 20:30:17 -0000 Mailing-List: contact musl-help@lists.openwall.com; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-ID: Original-Received: (qmail 11732 invoked from network); 31 Mar 2016 20:30:17 -0000 Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) Original-Sender: Rich Felker Xref: news.gmane.org gmane.linux.lib.musl.general:9803 Archived-At: On Thu, Mar 31, 2016 at 11:23:17PM +0300, Alexander Monakov wrote: > How size_t and friends are typedef'd is visible in C++ mangled names, so > unless I'm misunderstanding the context here, musl most likely doesn't want > to typedef them differently to what's typical on the platform. > > What about using compiler defines? GCC and Clang will predefine __SIZE_TYPE__ > and such, which is directly usable for typedef'ing size_t&co; see: > > :| gcc -xc - -E -dD|grep TYPE Changing them on an existing platform is not what's under discussion. The question was just about whether a new (virtual) arch can use [unsigned] long rather than [unsigned] int for these types without making things difficult for musl. Of course the compiler's choice of types has to match musl's, whichever definition is used. Rich