From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: =?UTF-8?Q?Cl=c3=a9ment_Pit-Claudel?= Newsgroups: gmane.emacs.devel Subject: Re: emacs-26: `with-eval-after-load' docstring omission Date: Fri, 13 Apr 2018 14:28:57 -0400 Message-ID: <171cd8bd-ea86-b8b0-2cbc-e9dcd04d8035@gmail.com> References: <827ed6de-fd90-144e-53dd-50163a937b63@gmail.com> <4e07d7b4-f1f7-0d5d-5f2a-b5e491ab4303@gmail.com> <35b3a8a6-6cf1-bb0b-c0b6-e8e25fa803fc@gmail.com> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Trace: blaine.gmane.org 1523644077 4376 195.159.176.226 (13 Apr 2018 18:27:57 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Fri, 13 Apr 2018 18:27:57 +0000 (UTC) User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.7.0 To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Apr 13 20:27:53 2018 Return-path: Envelope-to: ged-emacs-devel@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 1f73QL-0000vm-9S for ged-emacs-devel@m.gmane.org; Fri, 13 Apr 2018 20:27:49 +0200 Original-Received: from localhost ([::1]:44359 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1f73SR-0007xW-PO for ged-emacs-devel@m.gmane.org; Fri, 13 Apr 2018 14:29:59 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:56269) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1f73RZ-0007vq-He for emacs-devel@gnu.org; Fri, 13 Apr 2018 14:29:06 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1f73RU-00007O-Ht for emacs-devel@gnu.org; Fri, 13 Apr 2018 14:29:05 -0400 Original-Received: from mail-qk0-x232.google.com ([2607:f8b0:400d:c09::232]:37666) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1f73RU-00006r-DA for emacs-devel@gnu.org; Fri, 13 Apr 2018 14:29:00 -0400 Original-Received: by mail-qk0-x232.google.com with SMTP id w6so10069175qkb.4 for ; Fri, 13 Apr 2018 11:29:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:to:references:from:message-id:date:user-agent:mime-version :in-reply-to:content-language:content-transfer-encoding; bh=VnLVXBRVL9Zq2ckSHkmZloNNdH9kC5Lblh6a6/omeLk=; b=cfW0NIfVhhbqn0FtD8NGw5C2MhRpkdJpWGfsUttThb35xnATp5X8HmZVJGwM1atDeg bZsAmrGCunPK9LSb3ue7AqLc7zRWr8P1abijTxqwNNfqcuHBfA4hsfGUKRpuqtVL4kSa YtpIi/s/NgXikBrD/h5iKYO1oMYfOVE9uMDEQ/19mT9gvWIIi5NTyN/Bifrpfy9u6Suf unIhBkKhfajwnjlYQNKA+f+Pagwhe66cADWxAy+lwuXqOfLB/vrYrOlrSqpOcqcUMsNx Uj2MKATH1nOtBE1h5Qh79EAr7VBn1JstA8eCenNgJlYJ7/sERFiPmdCDhLC6EKI0fSqy j60g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=VnLVXBRVL9Zq2ckSHkmZloNNdH9kC5Lblh6a6/omeLk=; b=Ax1wJAgXpYAZ/sP0FU+ikn8kDG+jrc+a02TBZcioIZJtJTTYUA+vBt7EZN09UiV41v ZmhgUCn5OiSur07K1SJHVJWizlkVpSXv02zbZ1jThBZ/KTPmucDfM/+EHNXds+drkpcF QYEsiGhcvm5A1i6BbLz0ZGQ4DyXAQBaw6Q74qNM7A5ui18wN5GgiAX2sAKvQJ2YYOv2K oWnY2eBVwT+xvS7fWTOXOu65ST+zNAnFtIA06ty03BRoypzmQzfa/NgmCmcnPeFGATx6 unZjVvZuxQf5SbRFLNcp2zzqzRsqnC0eGnUePLF1dZnpvpH9EI50S/PUgVKbe7K7BNFg kbyA== X-Gm-Message-State: ALQs6tCXgOvWPAbdET47NufnhA2KiJ/0vYddcU6R3tuPqpZdYtDSDim5 s0EH/3tFpvdNWXEObD8UpJkXGB1W X-Google-Smtp-Source: AIpwx489jc9rB36Ao2zRb7G8dCNYxDY4CA0jyCuobEVOoVoTc+Y946MkcWE8Ly2frsBLQJXQPhDJGw== X-Received: by 10.55.71.71 with SMTP id u68mr5386633qka.357.1523644139751; Fri, 13 Apr 2018 11:28:59 -0700 (PDT) Original-Received: from [18.26.2.123] (26-2-123.dynamic.csail.mit.edu. [18.26.2.123]) by smtp.gmail.com with ESMTPSA id s6sm1949955qkc.7.2018.04.13.11.28.58 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 13 Apr 2018 11:28:58 -0700 (PDT) In-Reply-To: Content-Language: en-GB X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:400d:c09::232 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 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:224554 Archived-At: On 2018-04-13 14:02, Stefan Monnier wrote: > But in the case of flycheck-define-command at least, I don't see much > benefit to having it be a macro instead of some inert data in > a variable. Except that form (flycheck-define-checker) defines a variable, too, right? That is, it expands to a defvar and a function call. The concrete issue stems from users copying a form from flycheck.el intto their init file, without macro-expanding it. Of course, we can recommend that users copy the macro-expanded version (the defvar + the function call) — but that's not ideal, because not many of our users know how to do that (macroexpand a form). And macroexpanding all uses in flycheck.el isn't an option either. > I'd be perfectly happy to add a new macro like > > (defmacro with-lazy-macro-expansion (&rest body) > `(eval '(progn ,@body) lexical-binding)) > > but I'm reluctant to add a macro that's specific to eval-after-load > since the problem is more general. That would be nice. It would then be safe to do (with-eval-after-load (with-lazy-macro-expansion …)) right? Clément.