From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.bugs Subject: bug#15045: Point jumps inappropriately around time of Semantic lexing Date: Tue, 15 Oct 2013 09:42:03 -0400 Message-ID: References: <87pptptk9n.fsf@engster.org> <87eha4t7xz.fsf@engster.org> <8738qksz6l.fsf@engster.org> <837gfvua2r.fsf@gnu.org> <87y58bs9x4.fsf@engster.org> <83zjsrs3k2.fsf@gnu.org> <87pptmsv4z.fsf@engster.org> <83siyira0w.fsf@gnu.org> <87vc3drhuv.fsf@engster.org> <83haexrgjn.fsf@gnu.org> <83ppr7pr6c.fsf@gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; CHARSET=US-ASCII Content-Transfer-Encoding: 7BIT X-Trace: ger.gmane.org 1381844604 31089 80.91.229.3 (15 Oct 2013 13:43:24 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 15 Oct 2013 13:43:24 +0000 (UTC) Cc: Barry OReilly , 15045@debbugs.gnu.org, deng@randomsample.de, eric@siege-engine.com To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Tue Oct 15 15:43:27 2013 Return-path: Envelope-to: geb-bug-gnu-emacs@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 1VW4uA-0006tV-Hw for geb-bug-gnu-emacs@m.gmane.org; Tue, 15 Oct 2013 15:43:22 +0200 Original-Received: from localhost ([::1]:41908 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VW4uA-0006RL-11 for geb-bug-gnu-emacs@m.gmane.org; Tue, 15 Oct 2013 09:43:22 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:46602) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VW4u0-0006RA-86 for bug-gnu-emacs@gnu.org; Tue, 15 Oct 2013 09:43:19 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VW4tr-0000zc-6q for bug-gnu-emacs@gnu.org; Tue, 15 Oct 2013 09:43:12 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:36701) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VW4tr-0000zY-3X for bug-gnu-emacs@gnu.org; Tue, 15 Oct 2013 09:43:03 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1VW4tq-00063M-Hd for bug-gnu-emacs@gnu.org; Tue, 15 Oct 2013 09:43:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Stefan Monnier Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 15 Oct 2013 13:43:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 15045 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 15045-submit@debbugs.gnu.org id=B15045.138184452723199 (code B ref 15045); Tue, 15 Oct 2013 13:43:02 +0000 Original-Received: (at 15045) by debbugs.gnu.org; 15 Oct 2013 13:42:07 +0000 Original-Received: from localhost ([127.0.0.1]:50719 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1VW4sw-000625-Gt for submit@debbugs.gnu.org; Tue, 15 Oct 2013 09:42:06 -0400 Original-Received: from relais.videotron.ca ([24.201.245.36]:41329) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1VW4st-00061w-64 for 15045@debbugs.gnu.org; Tue, 15 Oct 2013 09:42:03 -0400 Original-Received: from ceviche.home ([24.201.53.56]) by VL-VM-MR006.ip.videotron.ca (Oracle Communications Messaging Exchange Server 7u4-22.01 64bit (built Apr 21 2011)) with ESMTP id <0MUP0039MQ225M90@VL-VM-MR006.ip.videotron.ca> for 15045@debbugs.gnu.org; Tue, 15 Oct 2013 09:42:02 -0400 (EDT) Original-Received: by ceviche.home (Postfix, from userid 20848) id BBD1666087; Tue, 15 Oct 2013 09:42:03 -0400 (EDT) In-reply-to: <83ppr7pr6c.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:79268 Archived-At: > FWIW, I'm against such changes. You can never know how many places > will be subtly broken by changes like that in such a popular > interface. Hmm... I kind of agree with both: - this is a subtle change affecting behavior in a corner case and it's difficult to know which code might care about it. - nothing in input-pending-p indicates this is some kind of blocking/waiting operation which might hence correspond to a "yield point". On the contrary, the intuition behind input-pending-p would make you think that the whole point of it is to let you find out if there's input *without waiting*. So I tend to agree with Barry that input-pending-p should not run timers. Not just based on his particular problem case, but on the basis of what ideally input-pending-p should do. Arguably it shouldn't process_special_events either, tho obviously, removing this call would introduce a known breakage, so we should keep this for now (until we have a better fix for it). > The original problem is rare enough, and should IMO be fixed in the > code where it happens. It can be difficult to "fix" it there, because there's simply no other operation that lets you detect if there's input in the queue without running arbitrary code, so it can require non-trivial refactoring. >> > What if input arrives because of a timer? >> If this is an issue, I propose input-pending-p return t if a timer is >> ready to run. > Likewise: too serious change in behavior for too obscure a reason. 100% agreement. `input-pending-p' is meant to detect *user input*, and timers do not count as such (and input generated by timers doesn't count as "user input" either). Stefan