From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Kaushal Modi Newsgroups: gmane.emacs.bugs Subject: bug#28492: 27.0.50; File mode specification error for some files during desktop-read Date: Mon, 18 Sep 2017 14:36:05 +0000 Message-ID: References: NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="089e0826726448c35d055977aa0b" X-Trace: blaine.gmane.org 1505745436 11780 195.159.176.226 (18 Sep 2017 14:37:16 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Mon, 18 Sep 2017 14:37:16 +0000 (UTC) To: 28492-done@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Mon Sep 18 16:37:12 2017 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dtxAd-0002pY-D4 for geb-bug-gnu-emacs@m.gmane.org; Mon, 18 Sep 2017 16:37:11 +0200 Original-Received: from localhost ([::1]:37017 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dtxAk-0003wc-Rw for geb-bug-gnu-emacs@m.gmane.org; Mon, 18 Sep 2017 10:37:18 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:54445) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dtxAY-0003tE-NF for bug-gnu-emacs@gnu.org; Mon, 18 Sep 2017 10:37:10 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dtxAU-0004Pr-M8 for bug-gnu-emacs@gnu.org; Mon, 18 Sep 2017 10:37:06 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:37861) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1dtxAU-0004PY-IJ for bug-gnu-emacs@gnu.org; Mon, 18 Sep 2017 10:37:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1dtxAU-00032V-7L for bug-gnu-emacs@gnu.org; Mon, 18 Sep 2017 10:37:02 -0400 In-Reply-To: Resent-From: Kaushal Modi Original-Sender: "Debbugs-submit" Resent-To: bug-gnu-emacs@gnu.org Resent-Date: Mon, 18 Sep 2017 14:37:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: cc-closed 28492 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Mail-Followup-To: 28492@debbugs.gnu.org, kaushal.modi@gmail.com, kaushal.modi@gmail.com Original-Received: via spool by 28492-done@debbugs.gnu.org id=D28492.150574538411626 (code D ref 28492); Mon, 18 Sep 2017 14:37:01 +0000 Original-Received: (at 28492-done) by debbugs.gnu.org; 18 Sep 2017 14:36:24 +0000 Original-Received: from localhost ([127.0.0.1]:46540 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dtx9s-00031R-21 for submit@debbugs.gnu.org; Mon, 18 Sep 2017 10:36:24 -0400 Original-Received: from mail-yw0-f170.google.com ([209.85.161.170]:54634) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dtx9q-00031F-I3 for 28492-done@debbugs.gnu.org; Mon, 18 Sep 2017 10:36:22 -0400 Original-Received: by mail-yw0-f170.google.com with SMTP id w9so471844ywi.11 for <28492-done@debbugs.gnu.org>; Mon, 18 Sep 2017 07:36:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:from:date:message-id:subject:to; bh=HPsn7wzH7yvcDsMXrdup/om7++fXuKi+ZPq6WsKufok=; b=bhVqrxoD4ZW/a5zJOcXVGwhWKPNVtJUbvzYkBStDaAzGcG5f+97bu9f+uLeI0bMOY6 yGPBbLEJnwwxOCpyiMj1wTYXsbqbCzD1PQ73LaxdhPJ8hiR/NHc8kDWZNb3xQvpWPVKT jmLdkX0ikLp6pYEKxhlabvhUSxADTS835yZnZAuGn1iL0J/0iUqlcPAIjOCq7+QYjsP7 m1+hG5UleGxsLIHou5H3dJEhkZWjM2pS+qUbHB43G2LyEacnQmx/bR4Z54+Bdz0aExyh eJsoi4niALinVZbJMr0PrV2AKw7GCZFpbSSAbRPbMNOt6eLHWG2iZn/OpQvHycXbr3/a C4CA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=HPsn7wzH7yvcDsMXrdup/om7++fXuKi+ZPq6WsKufok=; b=Tu46n357GjkQUQ+kZkigLA+KSYCsdQLaaslO6WWVcd0IBgKPuxbRj3JytxIUBlKIt2 +JiaftHYr92749Jj0AH3k+tZL5/9o5HUfoEJt9dcQ8wM8mNIGEI8xfLBdcbgiyRPZTcZ UcpNzOO7b7yPbISI/BJb+sWwn5cEFkUwwj1QGtFDMeBU/7wlbyKOr225wgjjHT4n+wIJ Ep3SfROBChGzp0GW4nqaXbqWOjdKBqWTsEL/33XQBazN3jLuVGbd5DmgvBQi7efq/iuq 23oFv6ngs+LiUo4sDUxE+AgK3BzJ5i8cLGsaT5tj2O1lEdo7kT4CUdF+mArd/8l0Yfg9 98/g== X-Gm-Message-State: AHPjjUhVvZsyp78wmCr1gMdC83EsmyH9MNKmTsp7kDLseKH+QPMopkPk L+GxGAAeH36mipVn4Mr7A2N9Z2ZXTUXwx8z0A9Q= X-Google-Smtp-Source: AOwi7QCMpWdwMH9rY9NQNtpqiL/qaEmhVd1ESY9DaNg3T7VQNG/azhG4LwqQeoXvlb1EBvlDorVHvfmPiWdTC8o212Y= X-Received: by 10.37.185.66 with SMTP id s2mr5965548ybm.318.1505745376426; Mon, 18 Sep 2017 07:36:16 -0700 (PDT) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:137052 Archived-At: --089e0826726448c35d055977aa0b Content-Type: text/plain; charset="UTF-8" Sorry about the noise. Turns out that a string-match-p was doing with a nil values variable in a function I added to the verilog-mode-hook. (And that variable was evaluating to nil only for a particular project.) The error backtrace was confusing though.. it looked like set-auto-mode was throwing the error. But actually it was set-auto-mode - set-auto-mode-0 - (funcall mode) - run-hooks .. (running the major mode hook) - One of the functions in that hook Is there a way so that an error like Error in one of the functions in verilog-mode-hook while running some.file gets printed instead of a misleading message that doesn't even mention the file causing it: File mode specification error: (wrong-type-argument stringp nil) -- Kaushal Modi --089e0826726448c35d055977aa0b Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Sorry about the noise.

Turns out that a= string-match-p was doing with a nil values variable in a function I added = to the verilog-mode-hook. (And that variable was evaluating to nil only for= a particular project.)

The error backtrace was co= nfusing though.. it looked like set-auto-mode was throwing the error.
=

But actually it was=C2=A0

set-= auto-mode
=C2=A0 - set-auto-mode-0
=C2=A0 =C2=A0 - (fun= call mode)
=C2=A0 =C2=A0 =C2=A0 - run-hooks .. (running the major= mode hook)
=C2=A0 =C2=A0 =C2=A0 =C2=A0 - One of the functions in= that hook

Is there a way so that an error like=C2= =A0

=C2=A0 =C2=A0 Error in one of the functions in= verilog-mode-hook while running some.file

gets pr= inted instead of a misleading message that doesn't even mention the fil= e causing it:=C2=A0

File mode specification err= or: (wrong-type-argument stringp nil)
--=

Kaushal Modi

--089e0826726448c35d055977aa0b--