unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: "Drew Adams" <drew.adams@oracle.com>
To: "'Lars Magne Ingebrigtsen'" <larsi@gnus.org>
Cc: 6695@debbugs.gnu.org
Subject: bug#6695: 24.0.50; thing-at-point-url-at-point and ffap-guesser problem
Date: Thu, 14 Jul 2011 09:29:19 -0700	[thread overview]
Message-ID: <0C6ECB66B9154AEFB52AD5EDD9B54E6F@us.oracle.com> (raw)
In-Reply-To: <m3tyap805m.fsf@quimbies.gnus.org>

> These both return nil for me in Emacs 24.

Yes.  So it is still not fixed, but is broken in another way.

Well, to be fair, punting and returning nil is not incorrect in the sense that
it gives the wrong URL.  It is incorrect in that it does not give the (correct)
URL at all.  It says, in effect, there is no URL at point, which is wrong.

> > Neither of those is remotely correct.
> >
> > 3. Put the cursor on the g of Settings.
> >    M-: (ffap-guesser) => nil

In the case of `ffap-guesser' it is perhaps too strong to say that a nil value
indicates that there is no URL at point (as in the `thing-at-point' case).  It
is only claiming to "guess", whereas `thing-at-point' returning nil claims that
there is no URL at point, and programs should be able to depend on that.

> > What should happen:
> >
> > `ffap-guesser' should return
> > "c:/Documents and Settings/foobar/My Documents/MyStuff/foo.pdf"
> >
> > `thing-at-point-url-at-point should return
> > "http://c:/Documents and Settings/foobar/My 
> Documents/MyStuff/foo.pdf"
> 
> I don't really see how guessing that these things are file names is
> feasible.

Why not?  That's their job.

> Unless one adds special matches for Windows where [letter]:/ matches
> stuff until the end of the line or something...

Maybe.  Dunno.  It would be good for someone knowledgable in thingatpt.el and
ffap.el take a look and see how these cases can be improved.

In the case of ffap.el, I guess you could call this an enhancement request,
since returning `nil' is just giving up and saying it has no "guess".  In the
case of thingatpt.el, this is a bug: it claims incorrectly that there is no URL
at point.






      reply	other threads:[~2011-07-14 16:29 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-07-21 18:16 bug#6695: 24.0.50; thing-at-point-url-at-point and ffap-guesser problem Drew Adams
2011-07-14 13:25 ` Lars Magne Ingebrigtsen
2011-07-14 16:29   ` Drew Adams [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=0C6ECB66B9154AEFB52AD5EDD9B54E6F@us.oracle.com \
    --to=drew.adams@oracle.com \
    --cc=6695@debbugs.gnu.org \
    --cc=larsi@gnus.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).