From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Alan Mackenzie Newsgroups: gmane.emacs.help Subject: Re: problem with ps-print-buffer-faces Date: Fri, 11 Nov 2011 15:18:47 +0000 (UTC) Organization: muc.de e.V. Message-ID: References: NNTP-Posting-Host: plane.gmane.org X-Trace: dough.gmane.org 1332967972 9152 80.91.229.3 (28 Mar 2012 20:52:52 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Wed, 28 Mar 2012 20:52:52 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Wed Mar 28 22:52:51 2012 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1SCzrO-00005v-TG for geh-help-gnu-emacs@m.gmane.org; Wed, 28 Mar 2012 22:52:51 +0200 Original-Received: from localhost ([::1]:51876 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SCzrO-0006te-6T for geh-help-gnu-emacs@m.gmane.org; Wed, 28 Mar 2012 16:52:50 -0400 Original-Path: usenet.stanford.edu!news-transit.tcx.org.uk!news2.arglkargh.de!feeder.erje.net!newsfeed.freenet.ag!news.space.net!news.muc.de!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 66 Original-NNTP-Posting-Host: news.muc.de Original-X-Trace: colin.muc.de 1321024727 85505 193.149.48.2 (11 Nov 2011 15:18:47 GMT) Original-X-Complaints-To: news-admin@muc.de Original-NNTP-Posting-Date: Fri, 11 Nov 2011 15:18:47 +0000 (UTC) User-Agent: tin/1.9.6-20101126 ("Burnside") (UNIX) (FreeBSD/8.2-STABLE (amd64)) Original-Xref: usenet.stanford.edu gnu.emacs.help:189767 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:84171 Archived-At: Jeffery Rancier wrote: > All: > When I attempt to call ps-print-buffer-faces in jde-mode or c-mode, I > get the follow error. Is this a problem with my ps-print module? > Suggestions? It looks very much like a bug in CC Mode which has already been fixed in the upcoming Emacs 24. If so, sorry about it. By the way, are you _sure_ that it happens in C Mode too? Would you please apply the following patch, recompile cc-fonts.el, and tell me whether or not it solves the problem. (If you're unsure about patches or compiling lisp files, send me a private email.) Here's the patch: *** orig/cc-fonts.el 2011-10-02 10:20:24.000000000 +0000 --- cc-fonts.el 2011-10-07 17:02:54.000000000 +0000 *************** *** 1526,1532 **** (setq decl-context (c-beginning-of-decl-1) in-typedef (looking-at c-typedef-key)) (if in-typedef (c-forward-token-2)) ! (when (looking-at c-opt-block-decls-with-vars-key) (goto-char ps-elt) (when (c-safe (c-forward-sexp)) (c-forward-syntactic-ws) --- 1529,1536 ---- (setq decl-context (c-beginning-of-decl-1) in-typedef (looking-at c-typedef-key)) (if in-typedef (c-forward-token-2)) ! (when (and c-opt-block-decls-with-vars-key ! (looking-at c-opt-block-decls-with-vars-key)) (goto-char ps-elt) (when (c-safe (c-forward-sexp)) (c-forward-syntactic-ws) > Platform: Windows XP > Emacs version: GNU Emacs 23.3.1 (i386-mingw-nt5.1.2600) of 2011-03-10 on 3249CTO > ps-print version : 7.3.5 > > Debugger entered--Lisp error: (wrong-type-argument stringp nil) > looking-at(nil) > c-font-lock-enclosing-decls(4773) > font-lock-fontify-keywords-region(2163 4773 nil) > font-lock-default-fontify-region(2163 4773 nil) > font-lock-fontify-region(2163 4773) > run-hook-with-args(font-lock-fontify-region 2163 4773) > byte-code("\302\303^H #\207" [start next run-hook-with-args jit-lock-functions] 4) > jit-lock-fontify-now(1 4773) > ps-print-ensure-fontified(1 4773) > ps-generate-postscript-with-faces(1 4773) > ps-generate(# 1 4773 ps-generate-postscript-with-faces) > ps-spool-with-faces(1 4773 nil) > ps-print-with-faces(1 4773 nil) > ps-print-buffer-with-faces(nil) > call-interactively(ps-print-buffer-with-faces nil nil) > -- Alan Mackenzie (Nuremberg, Germany).