From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0 ([2001:41d0:2:4a6f::]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id nuG3CaaViGAEJgEAgWs5BA (envelope-from ) for ; Wed, 28 Apr 2021 00:52:22 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0 with LMTPS id MBBhBKaViGDJaQAA1q6Kng (envelope-from ) for ; Tue, 27 Apr 2021 22:52:22 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 32E1916ED6 for ; Wed, 28 Apr 2021 00:52:21 +0200 (CEST) Received: from localhost ([::1]:60400 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lbWZ1-0008Nm-Qh for larch@yhetil.org; Tue, 27 Apr 2021 18:52:19 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:36942) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lbWYZ-0008Md-KT for emacs-orgmode@gnu.org; Tue, 27 Apr 2021 18:51:51 -0400 Received: from mailscanner.iro.umontreal.ca ([132.204.25.50]:33293) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lbWYX-0004dq-5J for emacs-orgmode@gnu.org; Tue, 27 Apr 2021 18:51:50 -0400 Received: from pmg3.iro.umontreal.ca (localhost [127.0.0.1]) by pmg3.iro.umontreal.ca (Proxmox) with ESMTP id B49E7441379; Tue, 27 Apr 2021 18:51:47 -0400 (EDT) Received: from mail01.iro.umontreal.ca (unknown [172.31.2.1]) by pmg3.iro.umontreal.ca (Proxmox) with ESMTP id 5158F441372; Tue, 27 Apr 2021 18:51:42 -0400 (EDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=iro.umontreal.ca; s=mail; t=1619563902; bh=Dk31PUVoqQN1wCQmkcpAZ/WSzy32IJE3BECZVNgVAAk=; h=From:To:Subject:References:Date:In-Reply-To:From; b=SMLQMuSR1Zcv9lHa/0jFcCg160O+T+QeYQJDmkTqPrvuIrdXHeo105rcSqlrTH3jo D8Z2Ap3lhcaVtVToPCdKWBocpZ1vxn2e9E0RSCVOdjvbK9q7vNAY01feIacGUch7Zi SPR1myo1YXGvaiDjE8MO+VSGDad6tg8eZWzHSPwz8KL3rW7Z9SmC4RlhokQBm2Bx3a 8707qwcYJoEn6f8OFWCgf49HdS+yTop5/cn+QyaKjhev3LqnriIAe7RcAwP7QuNxfn lOECmhpMNaXDciAyOyVNhi6I1JkQeDCrFjITK6MJlYDTSF2nrBuobPgm6e74FnvwTw JElhia67vhD+A== Received: from alfajor (unknown [157.52.10.47]) by mail01.iro.umontreal.ca (Postfix) with ESMTPSA id 24E1D120151; Tue, 27 Apr 2021 18:51:42 -0400 (EDT) From: Stefan Monnier To: emacs-orgmode@gnu.org Subject: Re: More use of lexical-binding in ox.el Message-ID: References: <87wnsnig8h.fsf@nicolasgoaziou.fr> Date: Tue, 27 Apr 2021 18:51:41 -0400 In-Reply-To: <87wnsnig8h.fsf@nicolasgoaziou.fr> (Nicolas Goaziou's message of "Tue, 27 Apr 2021 23:12:46 +0200") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-SPAM-INFO: Spam detection results: 0 ALL_TRUSTED -1 Passed through trusted hosts only via SMTP AWL -0.074 Adjusted score from AWL reputation of From: address BAYES_00 -1.9 Bayes spam probability is 0 to 1% DKIM_SIGNED 0.1 Message has a DKIM or DK signature, not necessarily valid DKIM_VALID -0.1 Message has at least one valid DKIM or DK signature DKIM_VALID_AU -0.1 Message has a valid DKIM or DK signature from author's domain Received-SPF: pass client-ip=132.204.25.50; envelope-from=monnier@iro.umontreal.ca; helo=mailscanner.iro.umontreal.ca X-Spam_score_int: -42 X-Spam_score: -4.3 X-Spam_bar: ---- X-Spam_report: (-4.3 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: "Emacs-orgmode" X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1619563941; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=w8AKKW1BDtWP7lAnEjGFgcKAIfvaFYxkKVujmVj43rI=; b=CqDBv00YuMQ1l83b+4xeFAM2OK0bNQB3Cl4YjQc2tfhNGDt8SV76V86aYcG/A/ev1/Eg1+ 99yy1K+ROtpg6txDpbfmvb+HG6uccPTMBEGftI7Tu4455/E+5+kuUYE4pdTsgZDnSsF3K2 QI5FTwYcms3WXpBg+eDAl6WRBck1NMnZzvdr/76z3yWaygHIVt1Y4whUyU+qdzX1FN7wPs IODVqYkf2rPRxqv+n1hH2UH2ORtc2LsqRCLPKGwmXPIB1Fx0mgdTiUFL8n84HsBhrCcOc7 Vj7qwghjZzB8DlZOGZrDIsn+ozXs0aoKo3XLEpcazDIDbhaARjqqt4+BGlquHw== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1619563941; a=rsa-sha256; cv=none; b=kq2p0XitYMPqDt8YmqyWROOfG6by459z/CFUET05lnoobDIxvov6HDfDvNUnfQM3myXCh4 +98n2NN2vTUHRZuYn9mgZUj40mKiWNEV9+41R+a5mBrGZXVFTWIZXW9uT0aYXeZ13/YnFl Xwk+uq93hDhc2OeWYtWz7PWcpwujBNYUonNoPJAN0sokRGYm3kzw+INSqMhEay84IFdWp1 MLRIR+ljw5vnHxSaE6ydq849CgLmqa0INf28X6i8Ae7bLYL0PAks3HNNCFWakIw556g1aY 2LdC5N3oqnhZzh8nJ37bXCxeUSY6VpqwlYy6HJ6rkvYFFjCF4Vk51GAaK3rkug== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=iro.umontreal.ca header.s=mail header.b=SMLQMuSR; spf=pass (aspmx1.migadu.com: domain of emacs-orgmode-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=emacs-orgmode-bounces@gnu.org X-Migadu-Spam-Score: -2.15 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=iro.umontreal.ca header.s=mail header.b=SMLQMuSR; dmarc=pass (policy=none) header.from=iro.umontreal.ca; spf=pass (aspmx1.migadu.com: domain of emacs-orgmode-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=emacs-orgmode-bounces@gnu.org X-Migadu-Queue-Id: 32E1916ED6 X-Spam-Score: -2.15 X-Migadu-Scanner: scn0.migadu.com X-TUID: 9REKXFvKsJuY > It looks great but it introduces a test failure, however. > > `org-export-expand-include-keyword' is called from within > `org-export-with-buffer-copy'. > > At the very beginning of `org-export-expand-include-keyword', there is > > (buffer-file-name (buffer-base-buffer)) > > Before the patch, it returned the source file name. After the patch it > returns nil. > > Actually I'm a bit surprised it used to work, since we're evaluating > this from a new buffer, not an existing one. But hey, it worked! That's because the "buffer copy" also copies the local vars, and indeed that's where I made a typo. > Do you know what could cause this? Yes: (push (cons var val) varvals)))) varvals))) should be (push (cons var val) varvals))))) varvals)) so that the final `varvals` is outside the `dolist` (it's the thing we want to return to store it in the outer `varvals` variable). Sorry 'bout that, Stefan