emacs-devel
[Top][All Lists]
Advanced

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

Re: [Psgml-devel] Re: Key sequence C-c C-f C-e uses invalid prefix chara


From: Peter Flynn
Subject: Re: [Psgml-devel] Re: Key sequence C-c C-f C-e uses invalid prefix characters
Date: Sun, 12 Jan 2003 14:29:49 +0000
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.1) Gecko/20020826

Miles Bader wrote:
On Wed, Dec 18, 2002 at 12:34:38AM +0000, Peter Flynn wrote:

There is no point in even attempting to edit SGML without a DTD,

Of course there's a point.  It may not be as nice as when you know the real
semantics (the results may be woefully wrong, if the grammar has lots of
implicit end tags or something), but it's still useful.

Not really, in the sense that you can't *use* the file in any normal way
unless it's valid. If you know the DTD by heart and you have a great eye
for accuracy, sure, you can edit the file using vi or Notepad or Emacs
with just sgml-mode and you'll probably get it very close to correct.

And there is at least one very important set of occasions when editing
SGML without a validating enviromment is significantly important, as
has been pointed out elsewhere
(http://www.qucis.queensu.ca/achallc97/papers/p041.html).

The results will almost certainly be woefully wrong for any non-trivial
case, so apart from the above I'm not clear how it could be said to be
"useful" except as a learning experience.

as a DTD is *required* by ISO 8859 for all processing.

It doesn't matter what the `standard requires,' it matters what users find
convenient.

This is meaningless. I can't supply a client with a broken document and
tell them that my author found it more "convenient" to edit without the
DTD and that the fact that they specified SGML according to a specific
DTD "doesn't matter". *I* didn't specify SGML conformance, *they* did,
and the fact that I may believe standards adherence to be wrong doesn't
change the fact that I have to supply what has been contracted for.

You might just as well say that even though the law says you must stop
at a red light, you find it more convenient to run the light.

In your view, if someone thinks that that "it doesn't matter" if the
ANSI C standard requires some aspect of C syntax that they don't like,
and if they find it more convenient to omit some declarations because
they get in the way, you believe these people should be at liberty to
do so and still claim they are writing C. I think not; and it won't work.

"The standard doesn't matter" means you can't be bothered your ass :-)
that's fine, it's your ass, and if you really don't like the SGML
standard (many don't), you are at complete liberty to go and make your
own system. You just can't call it SGML or XML.

(Many people, especially programmers, hate and despise SGML and XML very
deeply indeed because they are not programming languages, and because
they cannot be described using the shibboleths of standard Comp Sci Prog
Lang 101. We -- the SGML/XML community -- have failed to communicate and
educate about the difference between markup languages and programming,
and Computer Science has failed to adapt itself to include some of the
paradigms of markup.)

Think `graceful degradation' -- do the best you can, instead of pedantically
clinging to standards.

Graceful degradation is fine in the face of corrupted files, as I have
already explained. But when you are contracted to produce SGML there
is no point in producing nonsense-markup instead. A standard is a
standard, period. I didn't write them, but my customers require that I
adhere to them.

I'm not clear why you use the word "pedantic". Pedanticism is for
*off-standard* behaviour, like requiring adherence to optional features
as if they were compulsory. That is not the case under discussion here.

So when you can't get the SGML DTD,

Ah. Now *that's* a different problem entirely. If it never existed
(files created by people who didn't know what they were creating),
or the DTD is lost in the mists of time, then the simple solution
is to create one. There are programs to do this -- have been for
years -- and I even documented one in my 1998 book on SGML/XML tools,
called Fred (from OCLC). There are now many more for XML as well.

just pretend the file's XML, and you'll get `sort of reasonable'
> results.

Not with sgml-mode, and for the same reasons. But with an Emacs mode
that handles XML you can indeed edit the file as well-formed DTD-less
XML, and I have suggested this as a solution to malformed or broken
SGML on numerous occasions.

It's not `correct,' but it's probably still useful,

On the contrary, it will actually be perfectly "correct" (as
well-formed DTD-less XML) and it will probably be quite useful.

But it won't be what we have been calling SGML until you reference
or attach a DTD and validate it, if that's what you need.

> and sounds pretty easy to me*...

It's all very easy. It just needs to be done right (the easy way)
instead of wrong (the hard way).

///Peter





reply via email to

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