From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Juanma Barranquero Newsgroups: gmane.emacs.help Subject: Re: `comment-start' is nil Date: Wed, 12 Mar 2014 22:56:25 +0100 Message-ID: References: <878usf6qu5.fsf@yun.yagibdah.de> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1394661429 9459 80.91.229.3 (12 Mar 2014 21:57:09 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 12 Mar 2014 21:57:09 +0000 (UTC) To: Emacs Help List Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Wed Mar 12 22:57:19 2014 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 1WNr9K-0003J4-NF for geh-help-gnu-emacs@m.gmane.org; Wed, 12 Mar 2014 22:57:18 +0100 Original-Received: from localhost ([::1]:35105 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WNr9K-0007Wh-AC for geh-help-gnu-emacs@m.gmane.org; Wed, 12 Mar 2014 17:57:18 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:42395) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WNr9A-0007W4-6B for help-gnu-emacs@gnu.org; Wed, 12 Mar 2014 17:57:08 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WNr98-0006g4-NY for help-gnu-emacs@gnu.org; Wed, 12 Mar 2014 17:57:08 -0400 Original-Received: from mail-yk0-x230.google.com ([2607:f8b0:4002:c07::230]:48293) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WNr98-0006g0-JE for help-gnu-emacs@gnu.org; Wed, 12 Mar 2014 17:57:06 -0400 Original-Received: by mail-yk0-f176.google.com with SMTP id 19so393597ykq.7 for ; Wed, 12 Mar 2014 14:57:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :content-type:content-transfer-encoding; bh=lWgQeSaBoooW8usOddSk4jPifePPtQ6CtY5gh2X1i0I=; b=H409nlPT+/eTF6LDw3u7AcPG+67IuDCpIcIwqWDyI9cDJW2pLP6iwCs+NI4IUnes7v eFrQICcKgA3C+nIusGyD405NMj4R0WtZIu9znEVYvcdy3k2pSGnkWa6ierd2H3uMhwWd Mw6mIFS44a/MbwPWHBwNpJpc45x2svb5A+v+7+H6Vp8Itbw3yfiVWI9GWvExoWz46o93 thJp5JPrbV0ntrGgIlipxFONADvflI1uT4iD5tup4iy9j+NwYXk6Ybn9Eu9od3xuyrby 4GnzmQ9FlSo8S11iplUTgFmSrVZF6z2Qcb8YjAb74UwUPqSydkg5ZzNCA6Tmr8eJEQld Y/4Q== X-Received: by 10.236.108.202 with SMTP id q50mr4396174yhg.146.1394661425862; Wed, 12 Mar 2014 14:57:05 -0700 (PDT) Original-Received: by 10.170.163.3 with HTTP; Wed, 12 Mar 2014 14:56:25 -0700 (PDT) In-Reply-To: <878usf6qu5.fsf@yun.yagibdah.de> X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2607:f8b0:4002:c07::230 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:96478 Archived-At: On Wed, Mar 12, 2014 at 10:37 PM, lee wrote: > I=C2=B4m using desktop-mode to restore the previous session when starting > emacs. For some buffers that are restored this way, I=C2=B4m using a mod= e > I=C2=B4m working on. This mode employs a function to search for a regex = in > particular buffers. The regex involves `comment-start'. > > Unfortunately, at the time the function is running during start-up, the > value of `comment-start' is nil. > > > (let ((end-marker (concat "^" comment-start lsl-hi-lock-patterns-end-= marker))) > (message "comment-start with %s is %s" > (buffer-name) > comment-start) ...) > > > gives me messages like "comment-start with test-plane.fontify is nil". > Calling the same function later works fine because `comment-start' isn=C2= =B4t > nil anymore. We'll need more information. It is a major mode or a minor mode? If a minor, which major mode are these buffers? How it is your function run during the startup? How does the function get the buffer to run into? Etc, etc. J