From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp12.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id YFCCO1GQfWKLKwEAbAwnHQ (envelope-from ) for ; Fri, 13 May 2022 00:55:14 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp12.migadu.com with LMTPS id 2KJxO1GQfWLhJQEAauVa8A (envelope-from ) for ; Fri, 13 May 2022 00:55:13 +0200 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 8FBB22CCA3 for ; Fri, 13 May 2022 00:53:58 +0200 (CEST) Received: from localhost ([::1]:56704 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1npHgy-00058a-2g for larch@yhetil.org; Thu, 12 May 2022 18:53:56 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:45918) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1npHfm-00058G-Ou for emacs-orgmode@gnu.org; Thu, 12 May 2022 18:52:43 -0400 Received: from zimbra.cs.ucla.edu ([131.179.128.68]:53362) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1npHfk-0005up-Kx for emacs-orgmode@gnu.org; Thu, 12 May 2022 18:52:42 -0400 Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id 4773C16005C; Thu, 12 May 2022 15:52:37 -0700 (PDT) Received: from zimbra.cs.ucla.edu ([127.0.0.1]) by localhost (zimbra.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10032) with ESMTP id 9mTCg5Q8JCue; Thu, 12 May 2022 15:52:36 -0700 (PDT) Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id 9357616005E; Thu, 12 May 2022 15:52:36 -0700 (PDT) X-Virus-Scanned: amavisd-new at zimbra.cs.ucla.edu Received: from zimbra.cs.ucla.edu ([127.0.0.1]) by localhost (zimbra.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id I68WmKw9cIzH; Thu, 12 May 2022 15:52:36 -0700 (PDT) Received: from [131.179.64.200] (Penguin.CS.UCLA.EDU [131.179.64.200]) by zimbra.cs.ucla.edu (Postfix) with ESMTPSA id 77DCF16005C; Thu, 12 May 2022 15:52:36 -0700 (PDT) Message-ID: <1b78bf4b-386a-b240-2f2f-585064ce3ba4@cs.ucla.edu> Date: Thu, 12 May 2022 15:52:32 -0700 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.9.0 Subject: Re: [PATCH] org-macs.el: Do not compare wall time and file modification time Content-Language: en-US To: Max Nikulin Cc: emacs-orgmode References: <106f5128-680b-f25e-1316-f7308c49b625@gmail.com> <439411c0-7dae-9dfd-373a-c3779469003f@gmail.com> <2db7387c-4cbc-a7d2-9fa0-74f4d62d8a59@gmail.com> <0fbf0584-5565-7f6d-c889-43158143f292@gmail.com> From: Paul Eggert Organization: UCLA Computer Science Department In-Reply-To: <0fbf0584-5565-7f6d-c889-43158143f292@gmail.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Received-SPF: pass client-ip=131.179.128.68; envelope-from=eggert@cs.ucla.edu; helo=zimbra.cs.ucla.edu X-Spam_score_int: -41 X-Spam_score: -4.2 X-Spam_bar: ---- X-Spam_report: (-4.2 / 5.0 requ) BAYES_00=-1.9, NICE_REPLY_A=-0.001, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.29 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 X-Migadu-To: larch@yhetil.org X-Migadu-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1652396113; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=mLRXY4l+EgKw3/60YV2nt4r5sLxwtTw1NaP/rI/KGpY=; b=sivKM1l7GvfR6PBwOMJmXKC3PjOesmlRD+S/vUrSzqeCuYPkuCMpOQ069xRAQ53M+EOI4q 8WKeU1K1cpTIOWpNviHwBFvgUbvFEFvSUwRigF2AFcZTAw87CBPAoI1pWn5aX9Hp6v06rK 0wCbW/Sf81n6qPUWlM3AfkIjDO/rh39ZCum4EJQAzbekrl74fqynvecIWeZvOGcrvbalXB dEfHIsf85+epRMhK+3mX7DQwu2nuT2mBqvWexGbNRlo5JYbjaqujvvJZit65uR0o91MOh7 7YMlrnHo703yUQtiNzF5Pu59wy4uI3C5PfB8IN0gg+0X6ZImHbeLKNtZvdxEhQ== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1652396113; a=rsa-sha256; cv=none; b=rcGS5TSi6TLGwmz+/opOIlybCnGeWDROmHORasqwcF614avXGrzB4gcQa0Pq95nwV2umV+ I432CYOsaBLepdjAYnVPli0r3O1gpqbSF6TAA57tiIGxCdyAO/WpSeQFVGdd1WXhy+YFNM 2PbLhKJYZ+HxD3C7IFowwOOkM2tEPJdjoKAzldaqittQMZu95G+PSu0oC23JPWkFwjdee7 Y1tB49GlLbH6rDGpwuLEeWwO/fvTUmTYDuvnPFSMSU5QvnBrPQqe11CImVNbaVZ+U62d34 NT1uOjH0K7xK9LYnYr79Lhgu+bgFAA9ek+IDGiT91B12WxBJC3+je9oTrz5Whg== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org" X-Migadu-Spam-Score: -3.02 Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org" X-Migadu-Queue-Id: 8FBB22CCA3 X-Spam-Score: -3.02 X-Migadu-Scanner: scn0.migadu.com X-TUID: 4GEcQBd/PdFh On 5/12/22 09:55, Max Nikulin wrote: > + (unless (file-exists-p file) > + (error "File to tangle does not exist: %s" file)) > + (when (file-newer-than-file-p file tangled-file) > (org-babel-tangle-file file ... file-newer-than-file-p succeeds only if FILE exists, so in that case it'd be a bit more efficient to avoid testing FILE's existence again, e.g.: (cond ((file-newer-than-file-p file tangled-file) (org-bable-tangle-file file ...)) ((not (file-exists-p file)) (error "File to tangle does not exist: %s" file)))