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

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

Re: hangs when reading DTD


From: Daniel Pfeiffer
Subject: Re: hangs when reading DTD
Date: Sat, 13 Nov 2004 18:59:46 +0100

Saluton, Moin,

Juri Linkov <address@hidden> skribis:

> address@hidden (Daniel Pfeiffer) writes:
> >> A function might do a better job, and `set-auto-mode' should be
> >> improved to support this.
> >
> > What could a function do other than my regexp?
> 
> Something like `sgml-xml-auto-coding-function' and
> `sgml-html-meta-auto-coding-function'.  These are too similar in
> functionality, so I wonder if guessing modes and codings should be
> somehow merged to process file headers in just one step?

Both of these functions are wrong:  <?xml may not be preceded by anything, not
even whitespace.  Strings, like the encoding, may be "string" or 'string'. And
the html tags must be matched case insensitively, no matter what the user's
settings are, while xml should not. 

Besides that, it's an interesting approach, definitely a worthwhile
optimization!  I'm not sure about PostScript, I think that also implies a
specific encoding.  As for '# xmcd' files, at least the CDDB treats them as
Latin-1, which is a shame, since there are CDs in many other languages. 
Locally however, utf-8 also works.  Btw., VRML, which I mentioned for my
alist, also gives the encoding in its magic:

#VRML V1.0 ascii
#VRML V2.0 utf8

coralament / best Grötens / liebe Grüße / best regards / elkorajn salutojn
Daniel Pfeiffer

-- 
lerne / learn / apprends / lär dig / ucz się    Esperanto:
                              http://lernu.net/




reply via email to

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