From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: =?iso-8859-1?Q?Jo=E3o_T=E1vora?= Newsgroups: gmane.emacs.devel Subject: Re: Add a separate mode for .dir-locals.el Date: Thu, 17 Oct 2019 18:42:32 +0100 Message-ID: References: <2058328b-aee5-8cb1-2659-a793e1354517@mit.edu> <87wod4m7sr.fsf@gnus.org> <835zkndcz4.fsf@gnu.org> <83ftjrbjhm.fsf@gnu.org> <83ftjr9sx4.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="1033"; mail-complaints-to="usenet@blaine.gmane.org" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (windows-nt) Cc: cpitclaudel@gmail.com, monnier@iro.umontreal.ca, emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Oct 17 19:46:56 2019 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([209.51.188.17]) by blaine.gmane.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1iL9rU-00006R-87 for ged-emacs-devel@m.gmane.org; Thu, 17 Oct 2019 19:46:56 +0200 Original-Received: from localhost ([::1]:54942 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1iL9rS-0002zd-Ut for ged-emacs-devel@m.gmane.org; Thu, 17 Oct 2019 13:46:54 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:52982) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1iL9nK-0008SD-VO for emacs-devel@gnu.org; Thu, 17 Oct 2019 13:42:39 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1iL9nJ-0003OK-Se for emacs-devel@gnu.org; Thu, 17 Oct 2019 13:42:38 -0400 Original-Received: from mail-wm1-x330.google.com ([2a00:1450:4864:20::330]:39169) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1iL9nJ-0003Nr-Kg; Thu, 17 Oct 2019 13:42:37 -0400 Original-Received: by mail-wm1-x330.google.com with SMTP id v17so3421856wml.4; Thu, 17 Oct 2019 10:42:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version:content-transfer-encoding; bh=u43U4XtL7FH5gSPzYy4iNw5G2NfR56LlvifzLhvu5tM=; b=cqKGvMBKxB/Oq473ZSjNV2dj6VScgUfOc/+5PtRsvrcJTX5fYCPb4RSBgNUrlnBJwQ 6BWuqzYdBlUe1i0scdcgB5FnsDjmqmd5zECurkS/jhXrxNKa5sxeHVfzvsh/Xa/T9kpp 33Eh/lceb3B5b7stQzuOazGPHAOUhuxOCJHcChXssfCh6z7HfB6bmwQX57D2OfYVOjIY Vgn9ewbxtHJmWRAiSmupJH8GJ82EDV7PNn2ZN4btJBjrFbiq3/2aoNBARcMJmUL7T/Jo TnsX0Vt/PRJfZ+xHiJ2AD8LsK34pg9aJpQ9XDUgXT4b45fOXSUWIEtqp2WDH99xM1/Wu W1Ww== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version:content-transfer-encoding; bh=u43U4XtL7FH5gSPzYy4iNw5G2NfR56LlvifzLhvu5tM=; b=WlW00q9zWC+O1riy5PaoFk2uuRhhNEmMhemJ0oL6WT4PKFRg+5Q5hXEz8Scdpm436Z Bg9IC2oEGPn6tEVUjWlm43uROF+uepzVrtHAlu4RkNswnCPnu/upGGO5rSTWM5mvnnp5 Gd8dnHsru2XGOAofJ3at95iBTVXwckzYTXOJtP6dgwHpyG9UQTEpsOcLBVq+/PyyfLRw TKzirnzupLI47p2l4UsFjuDmW66sCoSPmi2NvuheoAC0JmwuElSwDsB517zC5DguhiAt UmJQkixGn76vH0XSQhtZBhMt6AXMroGMsKVyVAMcGRhOE6NW0HqDGg/VJEQrboxDQjDE i36Q== X-Gm-Message-State: APjAAAXa1v+kUWE3BUKxhtXNdfFL1S2BjkvYAaRDZR/bUpoBZ0KuMyUj U4eHKH2qAYo6PaQSK8F9v6JbH70q X-Google-Smtp-Source: APXvYqxVhBOrg5ASCrjax6KkRRU2eHRw/oEzTBMR7ILmxdKMxij9/V3zvW9BG4UmcPJ92KO/o2dMBg== X-Received: by 2002:a7b:caea:: with SMTP id t10mr4110823wml.38.1571334155597; Thu, 17 Oct 2019 10:42:35 -0700 (PDT) Original-Received: from GONDOMAR.yourcompany.com (mail1.siscog.pt. [89.115.233.242]) by smtp.gmail.com with ESMTPSA id o18sm3524898wrm.11.2019.10.17.10.42.34 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Thu, 17 Oct 2019 10:42:34 -0700 (PDT) In-Reply-To: <83ftjr9sx4.fsf@gnu.org> (Eli Zaretskii's message of "Thu, 17 Oct 2019 20:35:19 +0300") X-Antivirus: AVG (VPS 191015-6, 16-10-2019), Outbound message X-Antivirus-Status: Clean X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::330 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:241156 Archived-At: Eli Zaretskii writes: >> From: Jo=E3o T=E1vora >> Cc: Eli Zaretskii , Cl=E9ment Pit-Claudel >> , emacs-devel >> Date: Thu, 17 Oct 2019 18:04:26 +0100 >>=20 >> Stefan Monnier writes: >>=20 >> >>>> A better option would be to have a base `lisp-prog-mode` and hen >> >>>> derive emacs-lisp-mode from it. >> >>> Exactly. dir-locals-mode should share a parent with emacs-lisp-mode. >> >> Yes. Is this very hard to do? >> > >> > No, it should be straightforward. >> > See sample patch below. >>=20 >> Indeed, quite nice. Eli, would you also opposed to having .dir-locals.el >> buffers use emacs-lisp-data-mode by default? We could reuse it for >> other things other than dir-locals. > > As I said, I don't want to introduce a major mode for this tiny > problem. It's gross. If the problem is small but the best solution is equally small and cheap, then I think you should consider it. Stefan's solution isn't gross at all, it's the most correct way to reuse code in this situation. > As for other things, I'm not sure that they matter (no one complained > about them yet), I think Yuri just did, about lisp data files. Like Gnu's, for example, or ido.el's or recentf's. > and I'm not sure we have a good idea of what exactly does that entail. Using Stefan's patch and adding some entries to auto-mode-alist? Jo=E3o