Path: utzoo!attcan!uunet!wuarchive!brutus.cs.uiuc.edu!apple!rutgers!aramis.rutgers.edu!topaz.rutgers.edu!busboys.rutgers.edu!gaynor From: gaynor@busboys.rutgers.edu (Silver) Newsgroups: comp.emacs Subject: Today's Quiz Message-ID: Date: 3 Jul 90 20:42:03 GMT Reply-To: gaynor@topaz.rutgers.edu Organization: Rutgers Univ., New Brunswick, N.J. Lines: 27 I have a friend who was editing his .Xresources file. The first line of the file reads: #define FONT_MONO_10 *-courier-bold-*-normal-*-*-100-* Without knowing what the error is, can you sniff out the problem? I _am_ impressed. For those of you incapable of casting greater divinations, the error flashed in the minibuffer is: File mode specification error: (error "Lisp nesting exceeds max-lisp-eval-depth") Not much of a help, huh? At least it points you in the right direction, file mode specification, so you whip up a buffer on files.el, search around, and find normal-mode. (_I_ knew to look there right from the start, nyah!) normal-mode calls set-auto-mode. It attempts to glean the file's mode from the first line, if enclosed within "-*-". Oh, look at the line again, "normal" is so enclosed! So the file's mode must be normal-mode, so call it! normal-mode calls set-auto-mode. It attempts to glean the file's mode from the first line, if enclosed within "-*-". Oh, look at the line again, "normal" is so enclosed! So the file's mode must be normal-mode, so call it! normal-mode calls set-auto-mode. Ad infinitum, or max-lisp-eval-depth, whichever comes first. I always use file variables in deference to -*-, and forgot about it completely. They open up the door to some nasty trojan horses, though. (setq inhibit-local-variables t)! Regards, [Ag]