From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Alan Mackenzie Newsgroups: gmane.emacs.devel Subject: Re: Time to merge scratch/correct-warning-pos into master, perhaps? Date: Sat, 22 Jan 2022 11:41:49 +0000 Message-ID: References: <84fspor0dj.fsf@gmail.com> <84o84bmxy2.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="33029"; mail-complaints-to="usenet@ciao.gmane.io" Cc: emacs-devel@gnu.org To: Brahimi Saifullah Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Sat Jan 22 12:43:40 2022 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nBEny-0008NP-Vk for ged-emacs-devel@m.gmane-mx.org; Sat, 22 Jan 2022 12:43:38 +0100 Original-Received: from localhost ([::1]:39138 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nBEnx-0001Ml-IH for ged-emacs-devel@m.gmane-mx.org; Sat, 22 Jan 2022 06:43:37 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:52932) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nBEmO-0000eP-BX for emacs-devel@gnu.org; Sat, 22 Jan 2022 06:42:01 -0500 Original-Received: from colin.muc.de ([193.149.48.1]:63187 helo=mail.muc.de) by eggs.gnu.org with smtp (Exim 4.90_1) (envelope-from ) id 1nBEmJ-0006Ay-V1 for emacs-devel@gnu.org; Sat, 22 Jan 2022 06:41:58 -0500 Original-Received: (qmail 10510 invoked by uid 3782); 22 Jan 2022 11:41:53 -0000 Original-Received: from acm.muc.de (p2e5d54f8.dip0.t-ipconnect.de [46.93.84.248]) (using STARTTLS) by colin.muc.de (tmda-ofmipd) with ESMTP; Sat, 22 Jan 2022 12:41:53 +0100 Original-Received: (qmail 16116 invoked by uid 1000); 22 Jan 2022 11:41:49 -0000 Content-Disposition: inline In-Reply-To: <84o84bmxy2.fsf@gmail.com> X-Submission-Agent: TMDA/1.3.x (Ph3nix) X-Primary-Address: acm@muc.de Received-SPF: pass client-ip=193.149.48.1; envelope-from=acm@muc.de; helo=mail.muc.de X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 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-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:285200 Archived-At: Hello, Brahimi. Sorry it's taken time to get back to you. I got distracted from this matter by another project (speeding up the bootstrap build). On Sun, Jan 16, 2022 at 13:45:25 -0300, Brahimi Saifullah wrote: > Alan Mackenzie writes: > > I don't actually use Flymake mode. Could you possibly give me a recipe > > to reproduce the bug, then either Joćo or I can fix it. > Sure. > emacs -Q > M-x flymake-mode > Type anything. Thanks. That was helpful. > I've also further tracked down the issue to `byte-compile-log-warning': > (defun byte-compile-log-warning (string &optional fill level) > "Log a byte-compilation warning. > STRING, FILL and LEVEL are as described in > `byte-compile-log-warning-function', which see." > (funcall byte-compile-log-warning-function > string nil > fill ^^^ > level)) Thanks! Hey, why aren't you on the team? ;-) > The highlighted part used to be `byte-compile-last-position', > but it was replaced with nil. The default byte compile log warning > function doesn't make use of that value (which is why you wouldn't > ordinarily notice it's amiss), but Flymake's function does. I've amended the function such that POSITION is no longer an &optional parameter, to help other people avoid falling into the same trap. In place of that nil, I now give a proper position (I hope). With the current state of the git branch, flymake on a .el file now seems to be working for me. I've committed the fix (along with a few other amendments) and I'd be grateful indeed if you could take another look at it. I'm hoping to merge it into master very soon indeed. Again, many thanks for the help. -- Alan Mackenzie (Nuremberg, Germany).