From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Alan Mackenzie Newsgroups: gmane.emacs.bugs Subject: bug#23053: 25.0.92; error in cc-mode when editing C# file with a generic class inheritance Date: Sun, 20 Mar 2016 21:16:58 +0000 Message-ID: <20160320211657.GD3603@acm.fritz.box> References: NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Trace: ger.gmane.org 1458508522 15136 80.91.229.3 (20 Mar 2016 21:15:22 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 20 Mar 2016 21:15:22 +0000 (UTC) Cc: 23053@debbugs.gnu.org To: Saulius =?UTF-8?Q?Menkevi=C4=8Dius?= Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun Mar 20 22:15:11 2016 Return-path: Envelope-to: geb-bug-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 1ahkgo-00066n-OA for geb-bug-gnu-emacs@m.gmane.org; Sun, 20 Mar 2016 22:15:10 +0100 Original-Received: from localhost ([::1]:54528 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ahkgn-0004dE-Ks for geb-bug-gnu-emacs@m.gmane.org; Sun, 20 Mar 2016 17:15:09 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:40925) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ahkgj-0004bn-Db for bug-gnu-emacs@gnu.org; Sun, 20 Mar 2016 17:15:06 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ahkgg-0007SN-0o for bug-gnu-emacs@gnu.org; Sun, 20 Mar 2016 17:15:05 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:58803) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ahkgf-0007SJ-U5; Sun, 20 Mar 2016 17:15:01 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1ahkgf-0006Sh-NK; Sun, 20 Mar 2016 17:15:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Alan Mackenzie Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org, bug-cc-mode@gnu.org Resent-Date: Sun, 20 Mar 2016 21:15:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 23053 X-GNU-PR-Package: emacs,cc-mode X-GNU-PR-Keywords: Original-Received: via spool by 23053-submit@debbugs.gnu.org id=B23053.145850845424769 (code B ref 23053); Sun, 20 Mar 2016 21:15:01 +0000 Original-Received: (at 23053) by debbugs.gnu.org; 20 Mar 2016 21:14:14 +0000 Original-Received: from localhost ([127.0.0.1]:55930 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ahkft-0006RQ-PD for submit@debbugs.gnu.org; Sun, 20 Mar 2016 17:14:14 -0400 Original-Received: from mail.muc.de ([193.149.48.3]:22988) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ahkfr-0006RI-Qe for 23053@debbugs.gnu.org; Sun, 20 Mar 2016 17:14:12 -0400 Original-Received: (qmail 67984 invoked by uid 3782); 20 Mar 2016 21:14:10 -0000 Original-Received: from acm.muc.de (p5B146DE7.dip0.t-ipconnect.de [91.20.109.231]) by colin.muc.de (tmda-ofmipd) with ESMTP; Sun, 20 Mar 2016 22:14:09 +0100 Original-Received: (qmail 21379 invoked by uid 1000); 20 Mar 2016 21:16:58 -0000 Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.24 (2015-08-30) X-Delivery-Agent: TMDA/1.1.12 (Macallan) X-Primary-Address: acm@muc.de 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-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:115189 Archived-At: Hello, Saulius. On Sat, Mar 19, 2016 at 04:15:53PM +0200, Saulius Menkevičius wrote: > Hi, > Not sure why I did not receive and email directly from debbugs.gnu.org > (maybe there is some delay in mail transfer mechanism on the way). I answered your mail directly, with a copy to debbugs.gnu.org. But things can go wrong with email. > > Thanks for such an informative bug report. Could you possibly tell me > > what major mode you're using (presumably some C# Mode) and where I can > > get a copy of it from, please. That will enable me to reproduce the > > problem. > The mode in question is csharp-mode, from MELPA: > csharp-mode is a dependency package. > Status: Installed in ‘csharp-mode-20160217.1211/’ (unsigned). > Version: 20160217.1211 > Summary: C# mode derived mode > Homepage: https://github.com/josteink/csharp-mode > Keywords: c# languages oop mode > Other versions: 20160217.1211 (melpa-stable), 0.8.12 (marmelade). OK, I've got it, thanks. In particular, the 0.8.12 version from MELPA. Next question: have you actually compiled it with the emacs-25 repository code? What makes me think you might not have, is that there are lots of (looking-back ) instances in the code, which no longer compile. (They need to have a nil inserted after , giving (looking-back nil).) As soon as I made these edits, then recompiled csharp-mode.el inside the emacs-25 repo version, the code ran just fine. Actually, I think I had manually to load cc-langs.elc to get it to compile properly; I think the following line is missing from near the top of csharp-mode.el: (eval-when-compile (require 'cc-langs)) Explanation for the bug I saw: a new "language variable", c-<>-notable-chars-re, had been defined in CC Mode, but not compiled into the csharp-mode part. That left it's value at nil, rather than the string it should be. This nil then caused the error. But it could be I'm looking at totally the wrong problem. > Not sure if you've checked the tracked for this issue, but Jostein > Kjønigsen secure.kjonigsen.net> wrote: > I've run this test-case against the "regular" Windows build 24.5.1, > using latest csharp-mode package and it runs fine. Trying latest Emacs > from git master on Ubuntu I can reproduce this error systematically > using the exact same version of csharp-mode. Exact same source code, or exact same binary? The source code will need recompiling for the emacs-25 repo. csharp-mode.elc compiled for an earlier version will definitely produce this error on emacs-25. > So this is can be replicated with bare emacs-25 from git + csharp-mode from > MELPA. Also someone wrote that the same thing happens with Java mode too > where the code being edited uses generics (as C# and Java generics syntax is > very similar). The same thing happening on Java would surprise me. That would imply a different problem. So, to sum up: please make sure the compiled version of csharp-mode you're using has been compiled on the Emacs you're using it on. Thanks! > > > In GNU Emacs 25.0.92.3 (x86_64-apple-darwin15.3.0, NS appkit-1404.34 Version 10.11.3 (Build 15D21)) > > > of 2016-03-17 built on mbp.local > > > Repository revision: 9ab03f27fad7b1ae68dda7a2effd075658dcf184 > > > Windowing system distributor 'Apple', version 10.3.1404 > > > Configured using: > > > 'configure --with-gnutls --with-ns' > > > Configured features: > > > JPEG DBUS NOTIFY ACL GNUTLS LIBXML2 ZLIB TOOLKIT_SCROLL_BARS NS > > > Important settings: > > > value of $LANG: de_LT > > > locale-coding-system: utf-8 > > > Major mode: mu4e-headers > > ??? > Oh, it was my first time using `report-emacs-bug', -- I invoked > it from my mail client buffer instead of from the csharp-mode that has > issue itself. No, by "???" I just meant "mu4e-headers is something I'm not familiar with.". > Thanks! > -- > Saulius Menkevičius (saulius.menkevicius@gmail.com) -- Alan Mackenzie (Nuremberg, Germany).