bug-gnu-emacs
[Top][All Lists]
Advanced

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

Re: sgml-mode.el: html-close-tag


From: Stefan Monnier
Subject: Re: sgml-mode.el: html-close-tag
Date: 18 Feb 2002 12:38:50 -0500
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.2.50

>> These aren't really "empty tags" but tags for which it is legal (in SGML
>> but not in XML) to drop the closing tag.
> That's why I wanted to say _extra_ empty tags.
>> I agree that there should be
>> such a sgml-unclosed-tags (or some such name) and it could also be used
> Well, I still think that your idea of "unclosed tags" is just like
> my idea of "empty tags".

They are different:

        <input foo> bar

is basically equivalent to

        <input foo></input> bar

which is why it's called "empty" (there is nothing between the open and the
close).  In XHTML those tags are written as <input foo/>.  In contrast

        <p> foo
is like
        <p> foo </p>

It's not empty, but rather it's just not explicitly closed (the close-tag
is implicit and its precise location can depend on notions similar to
"precedence").

> I wanted to name it `sgml-extra-empty-tags' because from
> sgml-close-tag's point of view (and sgml-tag's point of view, as far
> as I can tell), it has the same purpose as `sgml-empty-tags'.

If sgml-xml is turned on, then sgml-tag will insert

        <input />
but
        <p></p>

So, no <p> does not behave the same as <input> from sgml-tag's point
of view.


        Stefan



reply via email to

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