emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: 23.0.0; (thing-at-point 'url) returns invalid urls


From: Drew Adams
Subject: RE: 23.0.0; (thing-at-point 'url) returns invalid urls
Date: Wed, 29 Aug 2007 15:37:42 -0700

> > Can you give me a specific example?
>
> I just mean the unqualified hostnames of machines on this network.  "www",
> "int", "lanleventsext", "phonebook", "financial", etc.

Yes.

URL syntax is quite variable. See http://www.ietf.org/rfc/rfc3986.txt.

Notice that "path" can be empty (no more slashes after http://, ftp:// or
whatever). This means that a URL with only http:// followed by an
"authority" (such as anythingyouwant) is valid URL syntax.

http://anythingyouwant is thus a valid URL, in terms of syntax. Whether or
not it links to something is another matter. But you have no guarantee that
http://www.google.com links to anything right now, either.

If you want validity in terms of live link target and not just URL syntax,
then the code would have to actually try the link. Some programs do just
that to test URL "validity". In this case, I'd say that that is not what is
called for, and Emacs already DTRT.






reply via email to

[Prev in Thread] Current Thread [Next in Thread]