+2012-01-21 Glenn Morris <rgm@gnu.org>
+
+ * modes.texi (Auto Major Mode):
+ * variables.texi (File Local Variables):
+ Mention inhibit-local-variables-regexps.
+
2012-01-19 Martin Rudalics <rudalics@gmx.at>
* windows.texi (Window Configurations): Rewrite references to
is @code{nil}, @code{set-auto-mode} does not check the @w{@samp{-*-}}
line, or near the end of the file, for any mode tag.
+@vindex inhibit-local-variables-regexps
+There are some file types where it is not appropriate to scan the file
+contents for a mode specifier. For example, a tar archive may happen to
+contain, near the end of the file, a member file that has a local
+variables section specifying a mode for that particular file. This
+should not be applied to the containing tar file. Similarly, a tiff
+image file might just happen to contain a first line that seems to
+match the @w{@samp{-*-}} pattern. For these reasons, both these file
+extensions are members of the list @var{inhibit-local-variables-regexps}.
+Add patterns to this list to prevent Emacs searching them for local
+variables of any kind (not just mode specifiers).
+
If @var{keep-mode-if-same} is non-@code{nil}, this function does not
call the mode command if the buffer is already in the proper major
mode. For instance, @code{set-visited-file-name} sets this to
@end table
@end defopt
+@defvar inhibit-local-variables-regexps
+This is a list of regular expressions. If a file has a name
+matching an element of this list, then it is not scanned for
+any form of file-local variable. For examples of why you might want
+to use this, @pxref{Auto Major Mode}.
+@end defvar
+
@defun hack-local-variables &optional mode-only
This function parses, and binds or evaluates as appropriate, any local
variables specified by the contents of the current buffer. The variable
*** Using "mode: MINOR-MODE" to enable a minor mode is deprecated.
Instead, use "eval: (minor-mode 1)".
-FIXME: inhibit-first-line-modes-regexps was not mentioned in lispref,
-but this probably should be.
++++
*** The variable `inhibit-first-line-modes-regexps' has been renamed
to `inhibit-local-variables-regexps'. As the name suggests, it now
applies to ALL file local variables, not just -*- mode ones.