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

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

bug#16573: 24.3; Auctex (11.87.2) in Elpa issues hundreds of warnings on


From: Tassilo Horn
Subject: bug#16573: 24.3; Auctex (11.87.2) in Elpa issues hundreds of warnings on compile
Date: Thu, 30 Jan 2014 11:27:40 +0100
User-agent: Gnus/5.130008 (Ma Gnus v0.8) Emacs/24.3.50 (gnu/linux)

Glenn Morris <address@hidden> writes:

>>> Personally I think this is bad practice.
>>
>> Why? 
>
> Well, what if you make a typo and use a function that is really
> undefined?

It'll throw at runtime, but hopefully it does so before shipping a
release.

>> As said, all those style files use LaTeX-* and TeX-* vars and
>> functions defined by AUCTeX's core.  However, the style files can't
>> be required individually, but AUCTeX itself loads them dynamically
>> depending on the \usepackages and \documentclass you use in your
>> LaTeX document.
>
> Why can't the style files require whatever AUCTeX files they need?

They could, I guess.  However, style files should be easy to write for
non-elisp experts.  They usually are nothing more than:

--8<---------------cut here---------------start------------->8---
(TeX-add-style-hook
 "<yourpackage-here>"
 (lambda ()
   (TeX-add-symbols
    '("<your-first-macro-here>" 1)  ;has one arg
    '("<your-2nd-macro-here>" 2)))) ;has two args
--8<---------------cut here---------------end--------------->8---

So that would need a (require 'tex), if it would also define latex
environments, it'll need (require 'latex) too, and if it'd also fiddles
with font-locking, it'll also (require 'font-latex).  I mean, we could
document in the manual section about writing custom style files which
AUCTeX files need to be required when using which function.  But style
files are usually written in parallel to working on/testing with a
sample tex document using the corresponding LaTeX style, so then the
functions/vars are defined anyway and one can just TAB your way through.

Another thing is that the style files reside in a subdirectory, so to
make the requires working their compilation would need a different
load-path.  (No big thing for the regular Makefile build job, but I'm
not sure about ELPA...)

And possibly adding requires would slow down the compilation process
quite a bit.  There are currently 144 style files.  As said, most of
them are rather short, but the tex, latex, and font-latex they'd need to
require are large (~14000 LOC in total).

>> Well, AUCTeX releases have a (setq byte-compile-warnings nil) in a
>> custom lpath.el that's used when byte-compiling anyway.
>
> Which makes this whole exercise rather laughable, doesn't it?

Kinda.  I didn't notice that before this bug report, too.  And I'll to
address the relevant warnings and remove that config.

> "All releases must ship with no warnings."
> <Disables warnings>
> "Job done!"

vc-annotate says:

  73660122 (Per Abrahamsen                 1996-08-29 20:32:16 +0000 6)

Good job, Per!  And it lasted for almost 18 years now.  ;-)

Bye,
Tassilo





reply via email to

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