[Doc-SIG] References in the same line as the target text

fantasai fantasai@escape.com
Sat, 06 Jul 2002 10:41:26 -0400


David Goodger wrote:
> 
> [fantasai]
> > Why would accepting curly braces in an email address preclude using
> > them to delimit a URI?
> 
> Because the parsing would be ambiguous.  Even if we could work around
> the corner cases, the code/regexp would be nightmarish.
> 
> > I think this:
> >     `inline hyperlink` { uri_with@weird,symbols }
> > looks much better than this:
> >     `inline hyperlink`__ __<uri_with@weird,symbols>
> 
> I disagree, for several reasons:
> 
> 1. Using whitespace like that is a kluge.  Line-wrap the text and you
>    could end up with::
> 
>        `inline hyperlink`_ {
>        uri_with@weird,symbols
>        }

You would only have to do that in very rare cases: a relative url with
an @ sign. Absolute urls must specify a scheme followed by a colon.
Colons aren't allowed in mail addresses, so the email parsing regex
wouldn't pick them up even if you left out the spaces.

> 2. Curly braces are very similar to parentheses, which cannot be used
>    because they're too common in text.

Can you give me an example? I don't remember the last time I saw
curly braces in non-mathmematical text.

> 3. There's overwhelming precedent for angle brackets with URLs.
..
> Angle brackets are familiar, standard URI delimiters.  Much better
> than curly braces.

Certainly, I agree, but as you said, they are already taken for SGML
notation. And this workaround:

   `inline hyperlink`__ __<uri>

Looks horrendous. If your goal is unobtrusive, that syntax fails
miserably. Seven consecutive punctuation characters--really, it's
not necessary.

Alternatives:

   a. This sentence contains an `inline hyperlink` {uri} which will direct
      you to some other resource.

   b. This sentence contains an `inline hyperlink` __<uri> which will direct
      you to some other resource.

   c. This sentence contains an `inline hyperlink` <"uri"> which will direct
      you to some other resource.

   d. This sentence contains an `inline hyperlink` >uri> which will direct
      you to some other resource.

   e. This sentence contains an `inline hyperlink` ^<uri> which will direct
      you to some other resource.

   f. This sentence contains an `inline hyperlink` [>uri] which will direct
      you to some other resource.

I personally like (c) and (f) the best.

~fantasai