From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Tino Calancha Newsgroups: gmane.emacs.bugs Subject: bug#24969: 26.0.50; number-at-point Date: Mon, 21 Nov 2016 22:09:41 +0900 Message-ID: <87polp7ze2.fsf@gmail.com> References: <87fumm9uti.fsf@gmx.net> <2b644637-6ade-b00f-aa35-07c390fc92c7@easy-emacs.de> <87twb2jkzs.fsf@users.sourceforge.net> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1479733918 2486 195.159.176.226 (21 Nov 2016 13:11:58 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Mon, 21 Nov 2016 13:11:58 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.0.50 (gnu/linux) Cc: Stephen Berman , tino.calancha@gmail.com, 24969@debbugs.gnu.org, npostavs@users.sourceforge.net To: Drew Adams Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Mon Nov 21 14:11:50 2016 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1c8oNw-0007lx-9O for geb-bug-gnu-emacs@m.gmane.org; Mon, 21 Nov 2016 14:11:48 +0100 Original-Received: from localhost ([::1]:49431 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1c8oNz-0000qt-ON for geb-bug-gnu-emacs@m.gmane.org; Mon, 21 Nov 2016 08:11:51 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:47053) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1c8oNI-0000VF-Hu for bug-gnu-emacs@gnu.org; Mon, 21 Nov 2016 08:11:09 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1c8oNC-0002q0-I1 for bug-gnu-emacs@gnu.org; Mon, 21 Nov 2016 08:11:08 -0500 Original-Received: from debbugs.gnu.org ([208.118.235.43]:49613) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1c8oNC-0002pu-EJ for bug-gnu-emacs@gnu.org; Mon, 21 Nov 2016 08:11:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1c8oNC-0001dS-3w for bug-gnu-emacs@gnu.org; Mon, 21 Nov 2016 08:11:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Tino Calancha Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 21 Nov 2016 13:11:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 24969 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: unreproducible Original-Received: via spool by 24969-submit@debbugs.gnu.org id=B24969.14797338056222 (code B ref 24969); Mon, 21 Nov 2016 13:11:02 +0000 Original-Received: (at 24969) by debbugs.gnu.org; 21 Nov 2016 13:10:05 +0000 Original-Received: from localhost ([127.0.0.1]:36779 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1c8oMH-0001cI-GR for submit@debbugs.gnu.org; Mon, 21 Nov 2016 08:10:05 -0500 Original-Received: from mail-pg0-f44.google.com ([74.125.83.44]:33406) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1c8oMG-0001bk-1G for 24969@debbugs.gnu.org; Mon, 21 Nov 2016 08:10:04 -0500 Original-Received: by mail-pg0-f44.google.com with SMTP id 3so130656335pgd.0 for <24969@debbugs.gnu.org>; Mon, 21 Nov 2016 05:10:04 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=QOG4hdSVOWrrW4mmpmyvkb8ulCQ5wtGpIFcJQmX5sTw=; b=F5sPyRrUKIEmVOuXGa4eu5AxZRJMjULVZ8EGJcO7wPBzQeVW5ADth7e+FE+Va81kC/ HzhLi1zG4muceU05t+3ofRRdeFLHwzT18LNQwViLWQwXUufDkzP5vlu5P/xAEeVzSIGz aJZp36AjlEa3O0fWGyPsCqsExArVPMAGdL8d/FWCirEVD85VRef8a/+Wt52Du4xvwLH9 cwRHKslhCZrTrP4KXTKbE9EPHS07kfqxHhIkt0YYQECa2m/iWKiISpYtG2q7ttd0snnZ 2gT85O3awA8qJMYBxeNHoCecyAmZD9nph2NLY9wcGkn8che6eDsmpAxN0NkxkuruzQXM 5vCA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=QOG4hdSVOWrrW4mmpmyvkb8ulCQ5wtGpIFcJQmX5sTw=; b=Mdd15pk1VDyT79hubK8LsopfuwbR4gzspJMgVhf6J0LZX14z0xJMY02udX0PXaWp0s vtgo/GrJaX/Jz5pagn+s+b+rL2yYXZaCAe6XW43Ldoc6/1ridJ3Gx+a1FWNMV++RQ+uZ JjRiTDGEmJzc0ageXabt/U2M7DyEWWaOQitWWptx3kwBJGkOym4ib51dKsTiBQGRXyg+ sq4BDBhqY1S+aXYnCeqOpRQ4v95nv4UVe2HIDHxr1wcGgjJI4T2Bu0Ac6rzqWsat9U0S gyd+OI4+z1Gbkm+J/nmosppO9F+YGb536bEF2gLwy79yRhuyS8GXn3DCuarTZ02uPA5B DclQ== X-Gm-Message-State: AKaTC00p/zpCA1oYtgL2lLA/A250tUWV37HN9GVON5epl8TZK3dVUnppS8jpXxkzLQMZzQ== X-Received: by 10.99.38.3 with SMTP id m3mr32022196pgm.113.1479733798099; Mon, 21 Nov 2016 05:09:58 -0800 (PST) Original-Received: from calancha-pc (57.92.100.220.dy.bbexcite.jp. [220.100.92.57]) by smtp.gmail.com with ESMTPSA id t193sm19694081pgb.4.2016.11.21.05.09.55 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Mon, 21 Nov 2016 05:09:57 -0800 (PST) In-Reply-To: (Drew Adams's message of "Sun, 20 Nov 2016 08:19:28 -0800 (PST)") X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.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" Xref: news.gmane.org gmane.emacs.bugs:125940 Archived-At: Drew Adams writes: > In Emacs 25.1 (emacs -Q), `number-at-point' at either > the `-' or the `1' returns nil, for me. And I do not > see why it should return a number. > > `number-at-point' is defined using `form-at-point' with > THING `sexp' and predicate `numberp'. The sexp picked > up at point is `foo-1', and that fails `numberp'. >From the time when i opened Bug#24605, the implementation, in master branch, of `number-at-point' was different: it changed in commit 786ab4a5 (Bug#8634). My patch was driven by this implementation. I didn't notice that `number-at-point' behaves different in emacs-25. > What am I missing? Why should this rightfully return > a number? I'm guessing that you are all using a more > recent version of `number-at-point' than what is in > Emacs 25.1 (?). But to me the Emacs 25.1 behavior I > see (i.e., returning nil) is correct. > > Did someone change the meaning of `number-at-point' > so that it now picks up a numeral that is not isolated? > If so, why would that be considered proper behavior? > At the very least it is not backward-compatible behavior. That's right. Commit above breaks backward-compatibility. >In Lisp, at least, there is no number at point, in `foo-2'. >That is, the Lisp parser (reader) would never pick up the >`2' as a number here. The doc string of `list-at-point' clearly says that the list should be a Lisp list. In the case of `number-at-point' the doc string just says 'the number at point', without connection with the Lisp parser. >IOW, I agree with the bug report that `form-at-point' >should - somehow - handle the case where `thing-at-point' >returns a non-string. There is a bug to be fixed. But >I'm not convinced that the fix we've implemented is TRT. Sure, I am open to alternative fixes.