From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Daiki Ueno Newsgroups: gmane.emacs.devel Subject: Re: XCHAR2B_BYTE[12] definitions in NS Date: Wed, 16 Jul 2014 14:46:43 +0900 Message-ID: References: NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1405489620 21194 80.91.229.3 (16 Jul 2014 05:47:00 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 16 Jul 2014 05:47:00 +0000 (UTC) Cc: emacs-devel@gnu.org To: Jan =?iso-8859-1?Q?Dj=E4rv?= Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Wed Jul 16 07:46:54 2014 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1X7I3J-0000Fn-8f for ged-emacs-devel@m.gmane.org; Wed, 16 Jul 2014 07:46:53 +0200 Original-Received: from localhost ([::1]:37754 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1X7I3I-0004MK-Sf for ged-emacs-devel@m.gmane.org; Wed, 16 Jul 2014 01:46:52 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:42268) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1X7I3F-0004MD-Jd for emacs-devel@gnu.org; Wed, 16 Jul 2014 01:46:50 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1X7I3E-0005V2-IU for emacs-devel@gnu.org; Wed, 16 Jul 2014 01:46:49 -0400 Original-Received: from fencepost.gnu.org ([2001:4830:134:3::e]:56606) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1X7I3E-0005Uy-FV for emacs-devel@gnu.org; Wed, 16 Jul 2014 01:46:48 -0400 Original-Received: from du-a.org ([2001:e41:db5e:fb14::1]:41999 helo=localhost.localdomain) by fencepost.gnu.org with esmtpsa (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1X7I3D-00017w-Ie; Wed, 16 Jul 2014 01:46:47 -0400 In-Reply-To: (Daiki Ueno's message of "Wed, 16 Jul 2014 13:14:49 +0900") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.4.50 (gnu/linux) X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2001:4830:134:3::e X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:173043 Archived-At: Daiki Ueno writes: > Jan Dj=E4rv writes: > >> They are used in xdisp.c which is generic code. >> W32 has similar macros. Maybe move to a common h-file and remove w32 >> and ns-specific macros? > > Makes sense, thanks for the suggestion. I've pushed a patch in that way > (r117538). I missed the fact that s->char2b is directly passed to the platform-dependent drawing functions: ExtTextOutW (W32) and CGContextShowGlyphsWithAdvances (NS), and the corresponding argument types are also platform-dependent: wchar_t * (W32) and unichar * (NS). So, IMO merging the macros into a single place will cause more confusion. I reverted the change and just installed the parentheses fix I initially posted. Sorry for all the fuss. Regards, -- Daiki Ueno