From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Paul Eggert Newsgroups: gmane.emacs.devel Subject: Re: [Emacs-diffs] master 6cd5678: Clarify compiler-pacifier in frame.c Date: Tue, 27 Aug 2019 00:28:58 -0700 Organization: UCLA Computer Science Department Message-ID: <834b9308-5235-be47-1cf8-136bb6f35e48@cs.ucla.edu> References: <835zmnjdjm.fsf@gnu.org> <227db16b-17d1-b44b-97b3-e80211415eef@cs.ucla.edu> <831rx9iupo.fsf@gnu.org> <32f9db09-0c04-df03-4bb7-76fe2aa9a88f@cs.ucla.edu> <83tva4fjkz.fsf@gnu.org> <87cb5a0c-bdd8-726c-80ed-92e9f3518a58@cs.ucla.edu> <83o90cfecf.fsf@gnu.org> <87lfvg3qbi.fsf@telefonica.net> <83imqjgb1g.fsf@gnu.org> <87ftln4wm0.fsf@telefonica.net> <83a7bvg4a2.fsf@gnu.org> <87blwb4u2i.fsf@telefonica.net> <835zmjg1re.fsf@gnu.org> <831rx7f863.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="172106"; mail-complaints-to="usenet@blaine.gmane.org" User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.8.0 Cc: emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Aug 27 09:29:37 2019 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([209.51.188.17]) by blaine.gmane.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1i2Vv6-000icX-Jn for ged-emacs-devel@m.gmane.org; Tue, 27 Aug 2019 09:29:36 +0200 Original-Received: from localhost ([::1]:47612 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1i2Vv5-0004ev-E3 for ged-emacs-devel@m.gmane.org; Tue, 27 Aug 2019 03:29:35 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:56954) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1i2Vud-0004en-Dl for emacs-devel@gnu.org; Tue, 27 Aug 2019 03:29:08 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1i2Vub-00010a-Qf for emacs-devel@gnu.org; Tue, 27 Aug 2019 03:29:06 -0400 Original-Received: from zimbra.cs.ucla.edu ([131.179.128.68]:44720) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1i2Vua-0000wS-4R; Tue, 27 Aug 2019 03:29:04 -0400 Original-Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id 00B881600CB; Tue, 27 Aug 2019 00:29:00 -0700 (PDT) Original-Received: from zimbra.cs.ucla.edu ([127.0.0.1]) by localhost (zimbra.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10032) with ESMTP id PO_8r-Fodi6W; Tue, 27 Aug 2019 00:28:59 -0700 (PDT) Original-Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id 3CE811600E6; Tue, 27 Aug 2019 00:28:59 -0700 (PDT) X-Virus-Scanned: amavisd-new at zimbra.cs.ucla.edu Original-Received: from zimbra.cs.ucla.edu ([127.0.0.1]) by localhost (zimbra.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id kxAcvAruqcT1; Tue, 27 Aug 2019 00:28:59 -0700 (PDT) Original-Received: from [192.168.1.9] (cpe-23-242-74-103.socal.res.rr.com [23.242.74.103]) by zimbra.cs.ucla.edu (Postfix) with ESMTPSA id 144301600CB; Tue, 27 Aug 2019 00:28:59 -0700 (PDT) In-Reply-To: <831rx7f863.fsf@gnu.org> Content-Language: en-US X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 131.179.128.68 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 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" Xref: news.gmane.org gmane.emacs.devel:239609 Archived-At: Eli Zaretskii wrote: > I think you didn't read the code of XParseGeometry (the one that is > executed on MS-Windows) well enough, if you think GCC gave a false > alarm. I just now reread that code in current master and still see only a false alarm. If that function returns a mask where (mask & XValue) != 0, then *x must have been set by this statement: 5298 if (mask & XValue) 5299 *x = clip_to_bounds (INT_MIN, tempX, INT_MAX); So, if GCC warns about the use of x in the calling code: 5342 int geometry = XParseGeometry (SSDATA (string), 5343 &x, &y, &width, &height); 5344 Lisp_Object result = Qnil; 5345 if (geometry & XValue) 5346 { 5347 Lisp_Object element; 5348 5349 if (x >= 0 && (geometry & XNegative)) ... then GCC is giving a false alarm: x must be initialized in line 5349 if (geometry & XValue) is nonzero in line 5345. If my reasoning is wrong, can you give the path through the function and its caller where x is used as an uninitialized variable? Because if there is such a path, we shouldn't be marking x with UNINIT; UNINIT is only for pacifying false alarms. Similarly for y.