From unknown Wed Jun 18 00:26:49 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#55635 <55635@debbugs.gnu.org> To: bug#55635 <55635@debbugs.gnu.org> Subject: Status: `make-decoded-time' incorrectly sets DST to nil, it should be -1 (guess) Reply-To: bug#55635 <55635@debbugs.gnu.org> Date: Wed, 18 Jun 2025 07:26:49 +0000 retitle 55635 `make-decoded-time' incorrectly sets DST to nil, it should be= -1 (guess) reassign 55635 emacs submitter 55635 Maxim Nikulin severity 55635 normal thanks From debbugs-submit-bounces@debbugs.gnu.org Wed May 25 10:47:02 2022 Received: (at submit) by debbugs.gnu.org; 25 May 2022 14:47:02 +0000 Received: from localhost ([127.0.0.1]:56212 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ntsHt-00016A-P1 for submit@debbugs.gnu.org; Wed, 25 May 2022 10:47:01 -0400 Received: from lists.gnu.org ([209.51.188.17]:46364) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ntsHs-00015z-AQ for submit@debbugs.gnu.org; Wed, 25 May 2022 10:47:00 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:44322) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ntsHr-0004eC-0p for bug-gnu-emacs@gnu.org; Wed, 25 May 2022 10:46:59 -0400 Received: from mail-lf1-x134.google.com ([2a00:1450:4864:20::134]:39437) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1ntsHp-0007hU-As for bug-gnu-emacs@gnu.org; Wed, 25 May 2022 10:46:58 -0400 Received: by mail-lf1-x134.google.com with SMTP id y32so36367689lfa.6 for ; Wed, 25 May 2022 07:46:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:message-id:date:mime-version:user-agent:to:content-language :subject:content-transfer-encoding; bh=6bckdsNsjy+VClOR73p50sN89C1BCVZPw1qqROCfGiU=; b=FD37sI28+q42AeJWqRolamRYNpb6JnVJoUD8JbbfQEBV0zxHgpgdoZD18PduBViO33 xKX6+uEOHsJPZKgLHDZOmF3dJsFUzDk3aGAg4NoovfGw8VCFgX2fm7ucqCAk1Vo6k987 XAcQ5jQTDe8C7bMmreHWtmo/hb6WB77MvlfqEZclGWL4CVaamqhZu2ecuLh4uR9ry24u cDr7jvFrQN7i2DdjZFitp4nRsmhdRAL8R0wcbLWYSIhsBEcp3qHZXY7Vv11enlVhcvfc 9zOyKTbRpqmILo22O2tTCpc9+9EcO0SW3JhuFQ0Y6eCDzoNUDhK0NXz+7Si2TEns70xr uHCQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:message-id:date:mime-version:user-agent:to :content-language:subject:content-transfer-encoding; bh=6bckdsNsjy+VClOR73p50sN89C1BCVZPw1qqROCfGiU=; b=L/J2iiB1L2PCoCLsT63mLBsPIUbs5XH+VNcZWcIXYSU2GSdSQ4cnB9JkM2pJkcOmp4 4+wgNBAlFqfUxaKxCuXcbU/o3dMCQ1SB7Lz/0rL5w4mgc5e+m0DtLHDPTdVQ6bIgrtS6 CiXMNvTLIZN+SBVjlwccLkOYsiLxL/KjXJb77WEjqe9GR/YlV7TjT9oxpixWOEcsabai 2BLvl8OLGIccE19kq0y4lFgp2tbA5kHa1UKMBtJrk46I2dnpOzKaZDimdi+dXPoJrphs o7dLrbUFzoGcPps28E1PwDGaSvcwxx1bNOZ+xaPkeF/bUCE+Jw0D9j6LVVpDp5L9VXxk s9tg== X-Gm-Message-State: AOAM5305rPR3AZu8KMZvB2AY5C+jrnXezyYAEfQxI+3Fac3TRmV8MCr+ BH2+Z3rEEVq8U2oDes3WKGcncw/QW1M= X-Google-Smtp-Source: ABdhPJxTVOwr4BVg6KrUun/k/7BL1VkmBVxwOAsxKELyCy+U/TBIdikmyNbFh/AYZzEzWfQhYgKsLw== X-Received: by 2002:a05:6512:e83:b0:477:bd0e:e54b with SMTP id bi3-20020a0565120e8300b00477bd0ee54bmr6814916lfb.191.1653490012073; Wed, 25 May 2022 07:46:52 -0700 (PDT) Received: from [192.168.0.101] (nat-0-0.nsk.sibset.net. [5.44.169.188]) by smtp.googlemail.com with ESMTPSA id z21-20020a19f715000000b00477cc3fa475sm2956489lfe.204.2022.05.25.07.46.51 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 25 May 2022 07:46:51 -0700 (PDT) From: Maxim Nikulin X-Google-Original-From: Maxim Nikulin Message-ID: <940415ce-2e31-ae18-3e16-8fdc54504a67@gmail.com> Date: Wed, 25 May 2022 21:46:50 +0700 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.8.1 To: bug-gnu-emacs@gnu.org Content-Language: en-US Subject: `make-decoded-time' incorrectly sets DST to nil, it should be -1 (guess) Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Received-SPF: pass client-ip=2a00:1450:4864:20::134; envelope-from=m.a.nikulin@gmail.com; helo=mail-lf1-x134.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, 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-Spam-Score: -1.3 (-) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.3 (--) Consider the following example: (format-time-string "%F %T %Z %z" (encode-time (make-decoded-time :year 2022 :month 3 :day 31 :hour 23 :minute 30 :second 0 :zone "Europe/Madrid")) "Europe/Madrid") "2022-04-01 00:30:00 CEST +0200" I believe that the result should be "2022-03-31 23:30:00 CEST +0200" It can be obtained if :dst -1 is explicitly added to the `make-decoded-time' arguments. Since `make-decoded-time' is defined using `cl-defun', I think, it is better to use -1 ("guess") default value for the :dst argument, not nil that explicitly says "no daylight saving time". There is `decoded-time-set-defaults', but it does not help (format-time-string "%F %T %Z %z" (encode-time (decoded-time-set-defaults (make-decoded-time :year 2022 :month 3 :day 31 :hour 23 :minute 30) "Europe/Madrid")) "Europe/Madrid") "2022-04-01 01:30:00 CEST +0200" This case I have no idea how to fix the issue. An example in the `decoded-time-add' docstring > (decoded-time-add (decode-time) (make-decoded-time :month 2)) adds even more confusion. If `make-decoded-time' is intended for intervals, not timestamps than it should not have DST and TZ values at all. Time interval may be added to timestamp, and time zone and daylight saving time flag is the property of particular timestamp while the same interval may be added to various timestamps and the actual result depends on the base timestamp. Timestamp and interval are different types and should not be used interchangeably. nil/t/-1 interpretation difference for DST causes issues like (bug#54731), so it should be handled with care. From debbugs-submit-bounces@debbugs.gnu.org Thu May 26 08:14:07 2022 Received: (at 55635) by debbugs.gnu.org; 26 May 2022 12:14:07 +0000 Received: from localhost ([127.0.0.1]:57192 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nuCNS-0004AL-Nf for submit@debbugs.gnu.org; Thu, 26 May 2022 08:14:06 -0400 Received: from quimby.gnus.org ([95.216.78.240]:56742) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nuCNP-00049d-CA for 55635@debbugs.gnu.org; Thu, 26 May 2022 08:14:05 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date: References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=g2dhkIWxsW25rzTo8lXkqUvEvaooOrEvGvzbFBS+SnY=; b=aWKtJuXCuFqLxEFzOYBDFq6cEM MIcoErGuBYnSmp7/tyQNJsSlcDyPwTAGl/YDwQ/26w4wK5lh7Fn4WkAnlOjNHLpaDbV01lzyeL2Hy DdJLEPyLlej/mI3PwX/4Nm72ZODAugMTzaG5RLFDGIbqmdf48c0J3PFrvROq2yMtJ8Hs=; Received: from [84.212.220.105] (helo=xo) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nuCNF-0004Nq-Af; Thu, 26 May 2022 14:13:55 +0200 From: Lars Ingebrigtsen To: Maxim Nikulin Subject: Re: bug#55635: `make-decoded-time' incorrectly sets DST to nil, it should be -1 (guess) References: <940415ce-2e31-ae18-3e16-8fdc54504a67@gmail.com> X-Now-Playing: Talking Heads's _The Name Of This Band Is Talking Heads (Disc 2: 1980-1981)_: "Drugs (Electricity)" Date: Thu, 26 May 2022 14:13:52 +0200 In-Reply-To: <940415ce-2e31-ae18-3e16-8fdc54504a67@gmail.com> (Maxim Nikulin's message of "Wed, 25 May 2022 21:46:50 +0700") Message-ID: <87o7zkbif3.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Maxim Nikulin writes: > Consider the following example: > > (format-time-string > "%F %T %Z %z" > (encode-time > (make-decoded-time :year 2022 :month 3 :day 31 > :hour 23 :minute 30 :second 0 > :zone "Europe/Madrid")) > "E [...] Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 55635 Cc: 55635@debbugs.gnu.org, Paul Eggert X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Maxim Nikulin writes: > Consider the following example: > > (format-time-string > "%F %T %Z %z" > (encode-time > (make-decoded-time :year 2022 :month 3 :day 31 > :hour 23 :minute 30 :second 0 > :zone "Europe/Madrid")) > "Europe/Madrid") > "2022-04-01 00:30:00 CEST +0200" > > I believe that the result should be > "2022-03-31 23:30:00 CEST +0200" > It can be obtained if :dst -1 is explicitly added to the > `make-decoded-time' arguments. > > Since `make-decoded-time' is defined using `cl-defun', I think, it is > better to use -1 ("guess") default value for the :dst argument, not > nil that explicitly says "no daylight saving time". I think that makes some sense, but on the other hand, that's just a simple helper function that does what it says -- "with only the keywords given filled out". But perhaps -1 is less "filled out" than nil in this case. > There is `decoded-time-set-defaults', but it does not help > > (format-time-string > "%F %T %Z %z" > (encode-time > (decoded-time-set-defaults > (make-decoded-time :year 2022 :month 3 :day 31 > :hour 23 :minute 30) > "Europe/Madrid")) > "Europe/Madrid") > "2022-04-01 01:30:00 CEST +0200" > > This case I have no idea how to fix the issue. It's this code, I guess: ;; When we don't have a time zone, default to DEFAULT-ZONE without ;; DST if DEFAULT-ZONE if given, and to unknown DST otherwise. (unless (decoded-time-zone time) (if default-zone (progn (setf (decoded-time-zone time) default-zone) (setf (decoded-time-dst time) nil)) (setf (decoded-time-dst time) -1))) I've added Paul to the CCs; perhaps he has some comments. -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no From debbugs-submit-bounces@debbugs.gnu.org Thu May 26 22:12:03 2022 Received: (at 55635) by debbugs.gnu.org; 27 May 2022 02:12:03 +0000 Received: from localhost ([127.0.0.1]:60418 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nuPSM-0005ER-Qr for submit@debbugs.gnu.org; Thu, 26 May 2022 22:12:03 -0400 Received: from zimbra.cs.ucla.edu ([131.179.128.68]:46712) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nuPSL-0005Dw-FE for 55635@debbugs.gnu.org; Thu, 26 May 2022 22:12:02 -0400 Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id A97BC1601A5; Thu, 26 May 2022 19:11:54 -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 Aavyc1WOMLtv; Thu, 26 May 2022 19:11:54 -0700 (PDT) Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id F327E1601BC; Thu, 26 May 2022 19:11:53 -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 Al58h6PZseJH; Thu, 26 May 2022 19:11:53 -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 C0CE11601B4; Thu, 26 May 2022 19:11:53 -0700 (PDT) Message-ID: <96e9d729-2e23-5637-3136-ac29e26aa287@cs.ucla.edu> Date: Thu, 26 May 2022 19:11:53 -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: bug#55635: `make-decoded-time' incorrectly sets DST to nil, it should be -1 (guess) Content-Language: en-US To: Lars Ingebrigtsen References: <940415ce-2e31-ae18-3e16-8fdc54504a67@gmail.com> <87o7zkbif3.fsf@gnus.org> From: Paul Eggert Organization: UCLA Computer Science Department In-Reply-To: <87o7zkbif3.fsf@gnus.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 55635 Cc: 55635@debbugs.gnu.org, Maxim Nikulin X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) On 5/26/22 05:13, Lars Ingebrigtsen wrote: > perhaps -1 is less "filled out" than nil in this > case. Indeed it is, and make-decoded-time's DST flag should default to -1. It's unfortunate that nil means "standard time" in these contexts. In hindsight some other symbol should have been used to mean "standard time". Could be too late to change this though. > It's this code, I guess: > > ;; When we don't have a time zone, default to DEFAULT-ZONE without > ;; DST if DEFAULT-ZONE if given, and to unknown DST otherwise. > (unless (decoded-time-zone time) > (if default-zone > (progn (setf (decoded-time-zone time) default-zone) > (setf (decoded-time-dst time) nil)) > (setf (decoded-time-dst time) -1))) This looks wrong. Shouldn't it leave the DST flag alone? I.e., just this: (unless (decoded-time-zone time) (setf (decoded-time-zone-time) default-zone)) That is, if we assume that for the DST component -1 means "unknown" and nil means "standard time", it should be OK for decoded-time-set-defaults to leave the DST component alone, for the same reason that it leaves the DOW component alone. From debbugs-submit-bounces@debbugs.gnu.org Fri May 27 06:41:01 2022 Received: (at 55635) by debbugs.gnu.org; 27 May 2022 10:41:01 +0000 Received: from localhost ([127.0.0.1]:32836 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nuXOu-0006GD-S4 for submit@debbugs.gnu.org; Fri, 27 May 2022 06:41:01 -0400 Received: from quimby.gnus.org ([95.216.78.240]:39114) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nuXOq-0006Fx-9l for 55635@debbugs.gnu.org; Fri, 27 May 2022 06:40:59 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Transfer-Encoding:Content-Type:MIME-Version:Message-ID :In-Reply-To:Date:References:Subject:Cc:To:From:Sender:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=kA9K4Lz8onUm1xL19MhYv2NCVqc9r40j3pKfMKwWFR8=; b=UmK3MkW4xK7rBwK4JfvEho3gFI e1RtJsMKoIx4ou1hMgCB52Eyg2JDzAxEouMZALfa+oc9K7IGla3JHIEkkvQULBHvohQS1A7tGd972 tLvC4qahcWzbiOlH5BlP049LTbl8fb1/Y7iCO5F9cMPon/zhLhmwjfO7wCCaurpwnexs=; Received: from [84.212.220.105] (helo=xo) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nuXOf-0006zX-TM; Fri, 27 May 2022 12:40:48 +0200 From: Lars Ingebrigtsen To: Paul Eggert Subject: Re: bug#55635: `make-decoded-time' incorrectly sets DST to nil, it should be -1 (guess) References: <940415ce-2e31-ae18-3e16-8fdc54504a67@gmail.com> <87o7zkbif3.fsf@gnus.org> <96e9d729-2e23-5637-3136-ac29e26aa287@cs.ucla.edu> X-Now-Playing: Hannah Diamond's _PC Music Volume 3_: "Invisible" Date: Fri, 27 May 2022 12:40:43 +0200 In-Reply-To: <96e9d729-2e23-5637-3136-ac29e26aa287@cs.ucla.edu> (Paul Eggert's message of "Thu, 26 May 2022 19:11:53 -0700") Message-ID: <87r14f8dhw.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Paul Eggert writes: >> perhaps -1 is less "filled out" than nil in this >> case. > > Indeed it is, and make-decoded-time's DST flag should default to -1. So I've now made this change in Emacs 29. Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 55635 Cc: 55635@debbugs.gnu.org, Maxim Nikulin X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Paul Eggert writes: >> perhaps -1 is less "filled out" than nil in this >> case. > > Indeed it is, and make-decoded-time's DST flag should default to -1. So I've now made this change in Emacs 29. >> It's this code, I guess: >> ;; When we don't have a time zone, default to DEFAULT-ZONE >> without >> ;; DST if DEFAULT-ZONE if given, and to unknown DST otherwise. >> (unless (decoded-time-zone time) >> (if default-zone >> (progn (setf (decoded-time-zone time) default-zone) >> (setf (decoded-time-dst time) nil)) >> (setf (decoded-time-dst time) -1))) > > This looks wrong. Shouldn't it leave the DST flag alone? I.e., just this: > > (unless (decoded-time-zone time) > (setf (decoded-time-zone-time) default-zone)) > > That is, if we assume that for the DST component -1 means "unknown" > and nil means "standard time", it should be OK for > decoded-time-set-defaults to leave the DST component alone, for the > same reason that it leaves the DOW component alone. Yes, I think so. But you changed this in a391ffa2f03, and you usually have a good reason for changes like this, so I thought there must be something subtle going on here I didn't quite get. =F0=9F=98=80 The old code doesn't look quite right, either, I think... - ;; When we don't have a time zone and we don't have a DST, then mark - ;; it as unknown. - (when (and (not (decoded-time-zone time)) - (not (decoded-time-dst time))) - (setf (decoded-time-dst time) -1)) - - (when (and (not (decoded-time-zone time)) - default-zone) - (setf (decoded-time-zone time) 0)) --=20 (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no From debbugs-submit-bounces@debbugs.gnu.org Fri May 27 15:27:08 2022 Received: (at 55635-done) by debbugs.gnu.org; 27 May 2022 19:27:08 +0000 Received: from localhost ([127.0.0.1]:35814 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nufc3-00063v-Tp for submit@debbugs.gnu.org; Fri, 27 May 2022 15:27:08 -0400 Received: from zimbra.cs.ucla.edu ([131.179.128.68]:36886) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nufc0-00063P-I7 for 55635-done@debbugs.gnu.org; Fri, 27 May 2022 15:27:06 -0400 Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id 88F331601D8; Fri, 27 May 2022 12:26:58 -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 o16EEjGnc04K; Fri, 27 May 2022 12:26:57 -0700 (PDT) Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id 82A6C1601F1; Fri, 27 May 2022 12:26:57 -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 Ub8w0V-4RwhB; Fri, 27 May 2022 12:26:57 -0700 (PDT) Received: from [192.168.1.9] (cpe-172-91-119-151.socal.res.rr.com [172.91.119.151]) by zimbra.cs.ucla.edu (Postfix) with ESMTPSA id 562F91601EC; Fri, 27 May 2022 12:26:57 -0700 (PDT) Content-Type: multipart/mixed; boundary="------------kELKUNklcM9uM8vRrftC61Jy" Message-ID: Date: Fri, 27 May 2022 12:26:56 -0700 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.9.1 Content-Language: en-US To: Lars Ingebrigtsen References: <940415ce-2e31-ae18-3e16-8fdc54504a67@gmail.com> <87o7zkbif3.fsf@gnus.org> <96e9d729-2e23-5637-3136-ac29e26aa287@cs.ucla.edu> <87r14f8dhw.fsf@gnus.org> From: Paul Eggert Organization: UCLA Computer Science Department Subject: Re: bug#55635: `make-decoded-time' incorrectly sets DST to nil, it should be -1 (guess) In-Reply-To: <87r14f8dhw.fsf@gnus.org> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 55635-done Cc: 55635-done@debbugs.gnu.org, Maxim Nikulin X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) This is a multi-part message in MIME format. --------------kELKUNklcM9uM8vRrftC61Jy Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: quoted-printable On 5/27/22 03:40, Lars Ingebrigtsen wrote: >> This looks wrong. Shouldn't it leave the DST flag alone? I.e., just th= is: >> >> (unless (decoded-time-zone time) >> (setf (decoded-time-zone-time) default-zone)) >> >> That is, if we assume that for the DST component -1 means "unknown" >> and nil means "standard time", it should be OK for >> decoded-time-set-defaults to leave the DST component alone, for the >> same reason that it leaves the DOW component alone. > Yes, I think so. But you changed this in a391ffa2f03, and you usually > have a good reason for changes like this, so I thought there must be > something subtle going on here I didn't quite get. =F0=9F=98=80 Thanks for the compliment, not sure it's deserved here.... > The old code doesn't look quite right, either, I think... >=20 > - ;; When we don't have a time zone and we don't have a DST, then mark > - ;; it as unknown. > - (when (and (not (decoded-time-zone time)) > - (not (decoded-time-dst time))) > - (setf (decoded-time-dst time) -1)) > - > - (when (and (not (decoded-time-zone time)) > - default-zone) > - (setf (decoded-time-zone time) 0)) Yes, that old code was wrong because it incorrectly assumeed that (not=20 (decoded-time-dst time)) means the DST flag is unspecified, whereas it=20 really means that the DST flag is specifying standard time. It also looked odd because default-zone was used only as a boolean, even=20 though its name suggests that it's the default time zone. This usage=20 dates back to commit fa648a59c9818ae284209ac7ae4f3700aebd92c9 which you=20 installed in July 2019. The only call using default-zone in Emacs is in=20 newsticker--decode-iso8601-date, which passes 0 so that the oddity in=20 the implementation makes no difference there. Part of the confusion here is that nil doesn't mean "no time zone is=20 known"; it means "use the Emacs default time zone". In other words, nil=20 has the same interpretation problem in time zones that it has in DST=20 flags - it doesn't mean "unknown". To try to lessen the confusion I installed the attached, which fixes the=20 reported bug so I'll close the bug report. Please feel free to revert if=20 you see a problem with it (I'm just trying to save time here by being bol= d). --------------kELKUNklcM9uM8vRrftC61Jy Content-Type: text/x-patch; charset=UTF-8; name="0001-decoded-time-set-defaults-now-leaves-DST-alone.patch" Content-Disposition: attachment; filename*0="0001-decoded-time-set-defaults-now-leaves-DST-alone.patch" Content-Transfer-Encoding: base64 RnJvbSBmZTM4Y2JjMTRmYjYyN2YzOWUxNDViOWE4NWYwMjlhZjk2ZjkwM2M3IE1vbiBTZXAg MTcgMDA6MDA6MDAgMjAwMQpGcm9tOiBQYXVsIEVnZ2VydCA8ZWdnZXJ0QGNzLnVjbGEuZWR1 P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vRrftC61Jy-- From debbugs-submit-bounces@debbugs.gnu.org Sat May 28 06:42:01 2022 Received: (at 55635-done) by debbugs.gnu.org; 28 May 2022 10:42:01 +0000 Received: from localhost ([127.0.0.1]:36459 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nuttQ-0001uV-Qa for submit@debbugs.gnu.org; Sat, 28 May 2022 06:42:01 -0400 Received: from quimby.gnus.org ([95.216.78.240]:50356) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nuttO-0001uJ-VU for 55635-done@debbugs.gnu.org; Sat, 28 May 2022 06:42:00 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date: References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=ifm7xnSk24H18am1iJZGU1ISPg3PUwv/zlwgQnzOJxs=; b=becGyz+8eo08CL0F4Fw4VZdUHx mcXRmJxWrGNxggPwPQvZ2SwuuKreYtFsac7FTuYeDJZ3M9s9IzaTtkW2geV/17/p+xUCcECfS+ZOm rqtmL5LyImXaTJs38U62OU0yxBL0hkMaJnwTiR3w3/6GFoCwbMERaou3wZUlhA8KUgnI=; Received: from [84.212.220.105] (helo=xo) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nuttE-0002Yn-If; Sat, 28 May 2022 12:41:51 +0200 From: Lars Ingebrigtsen To: Paul Eggert Subject: Re: bug#55635: `make-decoded-time' incorrectly sets DST to nil, it should be -1 (guess) References: <940415ce-2e31-ae18-3e16-8fdc54504a67@gmail.com> <87o7zkbif3.fsf@gnus.org> <96e9d729-2e23-5637-3136-ac29e26aa287@cs.ucla.edu> <87r14f8dhw.fsf@gnus.org> Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAABGdBTUEAALGPC/xhBQAAACBj SFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAAElBMVEXjt9O6bZgnLq2X TGZEJTf////hBHywAAAAAWJLR0QF+G/pxwAAAAd0SU1FB+YFHAofOUEuNigAAAG7SURBVDjLdZLr dcMgDIXB7gDIMEBLO0BUaYA4Yv+ZqgdxfNKEH20On++VdEVKz6fklPtnT/9P1vscoMRFSgDF/6fk gBCgUqVB0hDiIwOr0NDDIjxoR1Ns/QzYgODDapU2QsKjXq2GCgxk+e2hGMJa/aQA4jHsekgNqxyK ak4iWBVYv31a2fdGBjm4W5UVml4G2FkVsFgkOa1qMdSeSIEoWLzGBKagqnwG5l0hu9Eg+8ADgbJp gJliQAUsLblViq5aNGVzgCacS8yRToAyYUmHwmuI1RDwrvrndiouqtxtHUvvX6b4QD7aBYxuNwcy YnLS5N1qZvUxk0JilcT+FwczRMIKDJdHug3nBgmAy+VhtdIdYMZ8jdqPrHQ8fUXf+RoPa/N2XaGZ V6C13BVYayj05UAdvloA6Ek9ArAUaMzgVhqiXlA8uIGlNTmsbGI2CWlxapGtpWtXJP5XuyVUg8sB wCYxkL2Rq81uYOAcvGpDwwEE2CMqBTXrr5vuY5tASGgHCLDfawxfiCIoPBWzRixkpxoP5gmohGMx N518O4Hj3Ervr8GT1QnAG1CWvpzBntvPayvRuwP0N+ct+AOuNaunVkLiqAAAACV0RVh0ZGF0ZTpj cmVhdGUAMjAyMi0wNS0yOFQxMDozMTo1NyswMDowMN0B8eMAAAAldEVYdGRhdGU6bW9kaWZ5ADIw MjItMDUtMjhUMTA6MzE6NTcrMDA6MDCsXElfAAAAAElFTkSuQmCC X-Now-Playing: Snapped Ankles's _Forest of Your Problems_: "Shifting Basslines of the Cornucopians" Date: Sat, 28 May 2022 12:41:46 +0200 In-Reply-To: (Paul Eggert's message of "Fri, 27 May 2022 12:26:56 -0700") Message-ID: <87zgj23pn9.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Paul Eggert writes: > To try to lessen the confusion I installed the attached, which fixes > the reported bug so I'll close the bug report. Please feel free to > revert if you see a problem with it (I'm just trying to sa [...] Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 55635-done Cc: 55635-done@debbugs.gnu.org, Maxim Nikulin X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Paul Eggert writes: > To try to lessen the confusion I installed the attached, which fixes > the reported bug so I'll close the bug report. Please feel free to > revert if you see a problem with it (I'm just trying to save time here > by being bold). Thanks; I think that looks like the correct thing here. -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no From debbugs-submit-bounces@debbugs.gnu.org Sat May 28 12:31:53 2022 Received: (at 55635-done) by debbugs.gnu.org; 28 May 2022 16:31:53 +0000 Received: from localhost ([127.0.0.1]:38777 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nuzM1-00079e-Dq for submit@debbugs.gnu.org; Sat, 28 May 2022 12:31:53 -0400 Received: from mail-lf1-f45.google.com ([209.85.167.45]:35714) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nuzLz-00079K-BI for 55635-done@debbugs.gnu.org; Sat, 28 May 2022 12:31:51 -0400 Received: by mail-lf1-f45.google.com with SMTP id br17so11037871lfb.2 for <55635-done@debbugs.gnu.org>; Sat, 28 May 2022 09:31:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:message-id:date:mime-version:user-agent:subject :content-language:to:cc:references:in-reply-to :content-transfer-encoding; bh=wx0LbpPfOOWvPMi+bIT7+s52qEwhPsG79HYO7lXyCFM=; b=OB/h7FpajsaXWLXwr9FjgkC3ZxG4NAN1JUsnJsAzPSSM6he3SSEGPKdH2qVeV1Qpia OiubuRfKhBWI+a860y8VqEnWRKV/kPsIeywf0exEivLCRtKivgLtwAqe+O6Tmo5wcaFF Uy8r2vAgbyNGnb2ugEvGcqdsSk6LcirhJkgmtn8fW8qqzZoBdqhsCE208b6rhBtXchrt ezakCR8/LbeLduHCwWNtMVSUY9BOTadeyPuNfZUQqM3kKIAv+lh4AX29UEcJLf0LcDbq U9REWF1n2vF8cTYE3nYZJfeFvDRckujyQpaJSxfZ3D/61RW1aLYfAOs5rmfZQqGRfiWZ FxAg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:message-id:date:mime-version:user-agent :subject:content-language:to:cc:references:in-reply-to :content-transfer-encoding; bh=wx0LbpPfOOWvPMi+bIT7+s52qEwhPsG79HYO7lXyCFM=; b=tqo1dCvV4mwETib1DnYOLuDJk3fOKAYjEF+nmpwWlYm3VoL5SvfAkQLXTtTeny1wsK qEY/ZVYyEn4HKsYZ601d7X8e8zo4nVobXkG2euhWbIQP3drEhbEgtQc/A9zehzB7t/4L mJYaRVyUqBRhBRLIpqLPklVvwFD2eTVaeY2EPi2giP81BH4ktm2qGda4MOnU4FBd8rzM ujjEqJAAE1WkmvS2wHMdzWqMxzqRHT9XcNkLK5xrHai+v+9xHdaXcPEnDjOeQ2rtUuoC 8CDiMXUogW2txoyUO9kHEdMd5ZAz/2+ANgIz+yagCXdxwAaC4bpQtJFKwKWbqOupBMru Ec6w== X-Gm-Message-State: AOAM532dH0ZRJu/DPb1UfMb+ZhbIgqxR1cMcl0xruusFi34JbwC8GVAc nUr40wtjyStjlj+e9iA1kgUue/c23JX9k6Wp X-Google-Smtp-Source: ABdhPJxLM5qBX/9YERWRS1nV/1yCHyKjnHd8nit7ca+b67AdSgMoOOlT9qWuBP4vU5xe5GGO4IaA5Q== X-Received: by 2002:a05:6512:32c1:b0:478:6e6c:53a5 with SMTP id f1-20020a05651232c100b004786e6c53a5mr21563036lfg.435.1653755505062; Sat, 28 May 2022 09:31:45 -0700 (PDT) Received: from [192.168.0.101] (nat-0-0.nsk.sibset.net. [5.44.169.188]) by smtp.googlemail.com with ESMTPSA id d30-20020ac25ede000000b00477cab3374asm1384046lfq.303.2022.05.28.09.31.43 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sat, 28 May 2022 09:31:44 -0700 (PDT) From: Maxim Nikulin X-Google-Original-From: Maxim Nikulin Message-ID: <0e506652-fb7d-5707-8247-7747ff1e53b0@gmail.com> Date: Sat, 28 May 2022 23:31:43 +0700 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.8.1 Subject: Re: bug#55635: `make-decoded-time' incorrectly sets DST to nil, it should be -1 (guess) Content-Language: en-US To: Lars Ingebrigtsen , Paul Eggert References: <940415ce-2e31-ae18-3e16-8fdc54504a67@gmail.com> <87o7zkbif3.fsf@gnus.org> <96e9d729-2e23-5637-3136-ac29e26aa287@cs.ucla.edu> <87r14f8dhw.fsf@gnus.org> <87zgj23pn9.fsf@gnus.org> In-Reply-To: <87zgj23pn9.fsf@gnus.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Score: -0.0 (/) X-Debbugs-Envelope-To: 55635-done Cc: 55635-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) On 28/05/2022 17:41, Lars Ingebrigtsen wrote: > Paul Eggert writes: > >> To try to lessen the confusion I installed the attached, which fixes >> the reported bug so I'll close the bug report. Please feel free to >> revert if you see a problem with it (I'm just trying to save time here >> by being bold). > > Thanks; I think that looks like the correct thing here. Thank you, with the committed changes my examples work as I expect. Paul, do you have any comment concerning the last part of the bug report? `decoded-time-add' docstring: > (decoded-time-add (decode-time) (make-decoded-time :month 2)) I think, it is confusing that `make-decoded-time' is used to create timestamps *and* time intervals. They are different types, for example sum of intervals is meaningful (despite may be ambiguous) while there is no point to add timestamps. Daylight saving time and timezone are something alien for intervals. Though I am unsure if it is reasonable to mark intervals by e.g. 'time-interval symbol or to make these types distinct by some other way. From debbugs-submit-bounces@debbugs.gnu.org Sat May 28 12:53:59 2022 Received: (at 55635-done) by debbugs.gnu.org; 28 May 2022 16:53:59 +0000 Received: from localhost ([127.0.0.1]:38801 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nuzhP-0007kw-0T for submit@debbugs.gnu.org; Sat, 28 May 2022 12:53:59 -0400 Received: from eggs.gnu.org ([209.51.188.92]:46024) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nuzhN-0007ki-CK for 55635-done@debbugs.gnu.org; Sat, 28 May 2022 12:53:57 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:59496) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nuzhH-00071d-9x; Sat, 28 May 2022 12:53:51 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=Gv8WU2xhQROBXm2nMuK7fZfmtdf4weUxvKRVowX1fZY=; b=EGoTCCqpjhO2 8T46qo2YFvHhYhj+hPq6Z8l3/BCM6HUPlZ2cndd8b/1G4QamfULP9iSEv1z3OGHzHgWrIWck9wGwD sN8BX7HuYPXVZ+k4rO8SilOiK2mvogoVYr1ulXQblEyDRQ+rsdPVDHGSu3iQDtRnB6n75rVeSP6+Z SyDY7yfrDlHs3hDeowE8WC+eF9wKALf2DSEoh7csyFeNl7MG+kWYfysIBwsHP3gjudGZVqarkWef8 xia4QTxfnLX5MPTmyoZ2yNJ4lVs4mMCQ+NBk/MFucOQIltuvEw9cfr6qVTjPFnlrmDc2Ygzm01ZvJ uIyf/HNBGSqMjm3O+St4SA==; Received: from [87.69.77.57] (port=2293 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nuzhG-0000BJ-Pj; Sat, 28 May 2022 12:53:51 -0400 Date: Sat, 28 May 2022 19:53:47 +0300 Message-Id: <83o7zhlht0.fsf@gnu.org> From: Eli Zaretskii To: Maxim Nikulin In-Reply-To: <0e506652-fb7d-5707-8247-7747ff1e53b0@gmail.com> (message from Maxim Nikulin on Sat, 28 May 2022 23:31:43 +0700) Subject: Re: bug#55635: `make-decoded-time' incorrectly sets DST to nil, it should be -1 (guess) References: <940415ce-2e31-ae18-3e16-8fdc54504a67@gmail.com> <87o7zkbif3.fsf@gnus.org> <96e9d729-2e23-5637-3136-ac29e26aa287@cs.ucla.edu> <87r14f8dhw.fsf@gnus.org> <87zgj23pn9.fsf@gnus.org> <0e506652-fb7d-5707-8247-7747ff1e53b0@gmail.com> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 55635-done Cc: larsi@gnus.org, eggert@cs.ucla.edu, 55635-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > Cc: 55635-done@debbugs.gnu.org > From: Maxim Nikulin > Date: Sat, 28 May 2022 23:31:43 +0700 > > I think, it is confusing that `make-decoded-time' is used to create > timestamps *and* time intervals. They are different types, for example > sum of intervals is meaningful (despite may be ambiguous) while there is > no point to add timestamps. But this situation already exists with time units anyway. You can add an hour to some other time, but there's also a valid time stamp that expresses 1 hour past the epoch UTC, and their values are exactly identical. From debbugs-submit-bounces@debbugs.gnu.org Sat May 28 13:26:00 2022 Received: (at 55635-done) by debbugs.gnu.org; 28 May 2022 17:26:01 +0000 Received: from localhost ([127.0.0.1]:38847 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nv0CO-0002II-Ja for submit@debbugs.gnu.org; Sat, 28 May 2022 13:26:00 -0400 Received: from zimbra.cs.ucla.edu ([131.179.128.68]:56872) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nv0CN-0002I2-3V for 55635-done@debbugs.gnu.org; Sat, 28 May 2022 13:25:59 -0400 Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id 79097160091; Sat, 28 May 2022 10:25:53 -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 R7KozG6yxmdp; Sat, 28 May 2022 10:25:52 -0700 (PDT) Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id 5AB0D160172; Sat, 28 May 2022 10:25:52 -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 QW1vMfmwitQM; Sat, 28 May 2022 10:25:52 -0700 (PDT) Received: from [192.168.1.9] (cpe-172-91-119-151.socal.res.rr.com [172.91.119.151]) by zimbra.cs.ucla.edu (Postfix) with ESMTPSA id 16FF4160091; Sat, 28 May 2022 10:25:52 -0700 (PDT) Message-ID: Date: Sat, 28 May 2022 10:25:51 -0700 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.9.1 Content-Language: en-US To: Eli Zaretskii References: <940415ce-2e31-ae18-3e16-8fdc54504a67@gmail.com> <87o7zkbif3.fsf@gnus.org> <96e9d729-2e23-5637-3136-ac29e26aa287@cs.ucla.edu> <87r14f8dhw.fsf@gnus.org> <87zgj23pn9.fsf@gnus.org> <0e506652-fb7d-5707-8247-7747ff1e53b0@gmail.com> <83o7zhlht0.fsf@gnu.org> From: Paul Eggert Organization: UCLA Computer Science Department Subject: Re: bug#55635: `make-decoded-time' incorrectly sets DST to nil, it should be -1 (guess) In-Reply-To: <83o7zhlht0.fsf@gnu.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 55635-done Cc: larsi@gnus.org, 55635-done@debbugs.gnu.org, Maxim Nikulin X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) On 5/28/22 09:53, Eli Zaretskii wrote: > this situation already exists with time units anyway. You can add > an hour to some other time, but there's also a valid time stamp that > expresses 1 hour past the epoch UTC, and their values are exactly > identical. Quite true for encoded times that count seconds. However, Max also has a point that decoded timestamps like (19 17 10 28 5 2022 6 t -25200) are problematic as relative times. Although their first six elements can be treated as either relative or absolute, their last three elements don't make much sense in relative times. The recent change in the master branch that lets encode-time take six-element lists suggests that perhaps a better way to represent a relative decoded time would be as a 6-element list. With that in mind, here are three suggestions. 1. decoded-time-dst should return -1, instead of nil, when given a 6-element list, since nil means standard time and -1 means DST is unknown. 2. make-decoded-time should generate a six-element list unless given a DST or ZONE arg. 3. Document the above nicely. (This is the hardest part....) From debbugs-submit-bounces@debbugs.gnu.org Sun May 29 09:10:33 2022 Received: (at 55635-done) by debbugs.gnu.org; 29 May 2022 13:10:33 +0000 Received: from localhost ([127.0.0.1]:39633 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nvIgj-0000Tr-Ke for submit@debbugs.gnu.org; Sun, 29 May 2022 09:10:33 -0400 Received: from quimby.gnus.org ([95.216.78.240]:33302) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nvIgf-0000Tc-Ha for 55635-done@debbugs.gnu.org; Sun, 29 May 2022 09:10:33 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date: References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=VdmlWgl5cQYcBYZjBTZ6s17LaRT89O22PeyRY6rxsnc=; b=WYzVAvqm6uuM5/40jB+Ez9GqYX HYm2N86m9TWqgUfD0Q1n0tSD/bwWEwUkUpo5U2CPIbj5LHh4wnu7gMJUkuigQKa0oJzctaZ6ursyt ZxN36i9OGmu/jX9BKkGvVtufYKu3izz1tw0p2PJxMCerGCD5MvNr5iBJbMkHwfpUNovs=; Received: from [84.212.220.105] (helo=xo) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nvIgV-0004F0-Tp; Sun, 29 May 2022 15:10:22 +0200 From: Lars Ingebrigtsen To: Paul Eggert Subject: Re: bug#55635: `make-decoded-time' incorrectly sets DST to nil, it should be -1 (guess) References: <940415ce-2e31-ae18-3e16-8fdc54504a67@gmail.com> <87o7zkbif3.fsf@gnus.org> <96e9d729-2e23-5637-3136-ac29e26aa287@cs.ucla.edu> <87r14f8dhw.fsf@gnus.org> <87zgj23pn9.fsf@gnus.org> <0e506652-fb7d-5707-8247-7747ff1e53b0@gmail.com> <83o7zhlht0.fsf@gnu.org> Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAABGdBTUEAALGPC/xhBQAAACBj SFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAAD1BMVEV0L1p1PGCOV3rT yM/////+RlXKAAAAAWJLR0QEj2jZUQAAAAd0SU1FB+YFHQw7E9dMBY8AAAGnSURBVDjLbZTbgcQg CEXBaQCcBgQbmEj/ve3FPHR2l6+Yw0VeCRGRqrLW3lw6GTH38AiKaU3VdchgJSoRowf5NIBajIdV IXrFgALGqqYqbyvjA9Dh+IRCDHEt3pyk9xkKvhUuSEC01uZ6eE9XKDyfcAkhWuvFzzdXqPhoWpVR 3N5xAFCd4NDTzKnUaEuB29O4qfeBzB4QuByZMUv119hBUyGUjfqqtx1kN8CSsO8gMlR2E62obQeH izLCpcx3EC50G9cdDNWHYDILRCO5RbhqA+58K/QLpOYS2C8waFmGWMSQatMLjLIUfueXoZr2+GNO cWCn/gf6j2IYIZNvMO85AX8BSz//q8BcsSiuCWgCfyrBDNHpbENm5XYK2gNMuFh3k/4M5QRYY2G3 M+kx+94dwshxSm7hfUPeiXQHZiA+T3mcTe/pccxBRi62ne9nkkaZhbzvEtLKmGAeXld188A+mzjt vY+2bOC1qs4qFsgZIsdz5XQDnE11VL/24HyqyBcf6LYg17704YYG3aA/oMzJuf0GPH8bQPT4jeWy BJkLAMv9SY+2KX4A1oiDSpoAjkYAAAAldEVYdGRhdGU6Y3JlYXRlADIwMjItMDUtMjlUMTI6NTk6 MTkrMDA6MDA8IiopAAAAJXRFWHRkYXRlOm1vZGlmeQAyMDIyLTA1LTI5VDEyOjU5OjE5KzAwOjAw TX+SlQAAAABJRU5ErkJggg== X-Now-Playing: The Smiths's _The Smiths_: "Pretty Girls Make Graves" Date: Sun, 29 May 2022 15:10:19 +0200 In-Reply-To: (Paul Eggert's message of "Sat, 28 May 2022 10:25:51 -0700") Message-ID: <87sfos1o3o.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Paul Eggert writes: > With that in mind, here are three suggestions. > > 1. decoded-time-dst should return -1, instead of nil, when given a > 6-element list, since nil means standard time and -1 means DST is > unknown. Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 55635-done Cc: Eli Zaretskii , 55635-done@debbugs.gnu.org, Maxim Nikulin X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Paul Eggert writes: > With that in mind, here are three suggestions. > > 1. decoded-time-dst should return -1, instead of nil, when given a > 6-element list, since nil means standard time and -1 means DST is > unknown. I think that sounds correct. > 2. make-decoded-time should generate a six-element list unless given a > DST or ZONE arg. I don't think we should do this. Yes, the remaining elements are nonsensical when talking about intervals, but people rely on that function to return its documented value. If somebody wants to do interval calculations and passes in a DST to make-decoded-time, that's a classic "well, don't do that" situation. -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no From debbugs-submit-bounces@debbugs.gnu.org Sun May 29 18:04:50 2022 Received: (at 55635-done) by debbugs.gnu.org; 29 May 2022 22:04:50 +0000 Received: from localhost ([127.0.0.1]:42131 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nvR1m-0001ab-AR for submit@debbugs.gnu.org; Sun, 29 May 2022 18:04:50 -0400 Received: from zimbra.cs.ucla.edu ([131.179.128.68]:49300) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nvR1j-0001aL-7y for 55635-done@debbugs.gnu.org; Sun, 29 May 2022 18:04:48 -0400 Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id C6E02160124; Sun, 29 May 2022 15:04:41 -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 ztBkhBYIvUJX; Sun, 29 May 2022 15:04:40 -0700 (PDT) Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id 76B3A16015F; Sun, 29 May 2022 15:04:40 -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 0NH9XB1DbGKc; Sun, 29 May 2022 15:04:40 -0700 (PDT) Received: from [192.168.1.9] (cpe-172-91-119-151.socal.res.rr.com [172.91.119.151]) by zimbra.cs.ucla.edu (Postfix) with ESMTPSA id 41B58160124; Sun, 29 May 2022 15:04:40 -0700 (PDT) Content-Type: multipart/mixed; boundary="------------JZDXFu3tBLNnmLSAz0gB1EW8" Message-ID: <6ce0d14a-017c-2b28-d924-fb461396c547@cs.ucla.edu> Date: Sun, 29 May 2022 15:04:38 -0700 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.9.1 Content-Language: en-US To: Lars Ingebrigtsen References: <940415ce-2e31-ae18-3e16-8fdc54504a67@gmail.com> <87o7zkbif3.fsf@gnus.org> <96e9d729-2e23-5637-3136-ac29e26aa287@cs.ucla.edu> <87r14f8dhw.fsf@gnus.org> <87zgj23pn9.fsf@gnus.org> <0e506652-fb7d-5707-8247-7747ff1e53b0@gmail.com> <83o7zhlht0.fsf@gnu.org> <87sfos1o3o.fsf@gnus.org> From: Paul Eggert Organization: UCLA Computer Science Department Subject: Re: bug#55635: `make-decoded-time' incorrectly sets DST to nil, it should be -1 (guess) In-Reply-To: <87sfos1o3o.fsf@gnus.org> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 55635-done Cc: Eli Zaretskii , 55635-done@debbugs.gnu.org, Maxim Nikulin X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) This is a multi-part message in MIME format. --------------JZDXFu3tBLNnmLSAz0gB1EW8 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit On 5/29/22 06:10, Lars Ingebrigtsen wrote: > Paul Eggert writes: > >> With that in mind, here are three suggestions. >> >> 1. decoded-time-dst should return -1, instead of nil, when given a >> 6-element list, since nil means standard time and -1 means DST is >> unknown. > > I think that sounds correct. I looked into that, and since decoded-time-dst is defined by cl-defstruct it's not easy to change how it works. For now, I just documented the glitch; see the 3rd attached patch. I also installed the 1st attached patch which mentions that Emacs's decoded dst flag differs from that of Common Lisp, and the 2nd attached patch which makes iso8601 parsing compatible with what we've discussed here by having it return -1 for unknown DST flags. >> > 2. make-decoded-time should generate a six-element list unless given a >> > DST or ZONE arg. > > I don't think we should do this. OK, I left that alone. --------------JZDXFu3tBLNnmLSAz0gB1EW8 Content-Type: text/x-patch; charset=UTF-8; name="0001-Doc-fix-for-dst-flag.patch" Content-Disposition: attachment; filename="0001-Doc-fix-for-dst-flag.patch" Content-Transfer-Encoding: base64 RnJvbSAwMWU4MTRiNmVlZTcwZDdiYTYzYjRiYzJiMTgzZTQzYjkwMGVkMTg3IE1vbiBTZXAg MTcgMDA6MDA6MDAgMjAwMQpGcm9tOiBQYXVsIEVnZ2VydCA8ZWdnZXJ0QGNzLnVjbGEuZWR1 PgpEYXRlOiBTdW4sIDI5IE1heSAyMDIyIDA4OjUyOjEzIC0wNzAwClN1YmplY3Q6IFtQQVRD SCAxLzNdIERvYyBmaXggZm9yIGRzdCBmbGFnCgoqIGRvYy9saXNwcmVmL29zLnRleGkgKFRp bWUgQ29udmVyc2lvbik6IE5vdGUgQ29tbW9uIExpc3AgZHN0IGRpZmZlcnMuCi0tLQogZG9j L2xpc3ByZWYvb3MudGV4aSB8IDQgKystLQogMSBmaWxlIGNoYW5nZWQsIDIgaW5zZXJ0aW9u cygrKSwgMiBkZWxldGlvbnMoLSkKCmRpZmYgLS1naXQgYS9kb2MvbGlzcHJlZi9vcy50ZXhp IGIvZG9jL2xpc3ByZWYvb3MudGV4aQppbmRleCBmNGRkMmU3MDcyLi4xMWEwZDAyMzM4IDEw MDY0NAotLS0gYS9kb2MvbGlzcHJlZi9vcy50ZXhpCisrKyBiL2RvYy9saXNwcmVmL29zLnRl eGkKQEAgLTE2NDksOCArMTY0OSw4IEBAIFRpbWUgQ29udmVyc2lvbgogYSBwYXJ0aWN1bGFy IGZvcm0gc2hvdWxkIHNwZWNpZnkgQHZhcntmb3JtfS4KIAogQHN0cm9uZ3tDb21tb24gTGlz cCBOb3RlOn0gQ29tbW9uIExpc3AgaGFzIGRpZmZlcmVudCBtZWFuaW5ncyBmb3IKLUB2YXJ7 ZG93fSBhbmQgQHZhcnt1dGNvZmZ9LCBhbmQgaXRzIEB2YXJ7c2Vjb25kfSBpcyBhbiBpbnRl Z2VyIGJldHdlZW4KLTAgYW5kIDU5IGluY2x1c2l2ZS4KK0B2YXJ7ZG93fSwgQGNvZGV7ZHN0 fSBhbmQgQHZhcnt1dGNvZmZ9LCBhbmQgaXRzIEB2YXJ7c2Vjb25kfSBpcyBhbgoraW50ZWdl ciBiZXR3ZWVuIDAgYW5kIDU5IGluY2x1c2l2ZS4KIAogVG8gYWNjZXNzIChvciBhbHRlcikg dGhlIGVsZW1lbnRzIGluIHRoZSBjYWxlbmRyaWNhbCBpbmZvcm1hdGlvbiwgdGhlCiBAY29k ZXtkZWNvZGVkLXRpbWUtc2Vjb25kfSwgQGNvZGV7ZGVjb2RlZC10aW1lLW1pbnV0ZX0sCi0t IAoyLjM0LjEKCg== --------------JZDXFu3tBLNnmLSAz0gB1EW8 Content-Type: text/x-patch; charset=UTF-8; name="0002-ISO-8601-strings-sans-Z-don-t-specify-DST-flag.patch" Content-Disposition: attachment; filename*0="0002-ISO-8601-strings-sans-Z-don-t-specify-DST-flag.patch" Content-Transfer-Encoding: base64 RnJvbSA0NzczMDJkNDkwYWRmM2U3YzRjMWQ3NzJhYWJhN2RiZGQ0NTRiNjBhIE1vbiBTZXAg MTcgMDA6MDA6MDAgMjAwMQpGcm9tOiBQYXVsIEVnZ2VydCA8ZWdnZXJ0QGNzLnVjbGEuZWR1 PgpEYXRlOiBTdW4sIDI5IE1heSAyMDIyIDEzOjA3OjUwIC0wNzAwClN1YmplY3Q6IFtQQVRD SCAyLzNdID0/VVRGLTg/cT9JU089MjA4NjAxPTIwc3RyaW5ncz0yMHNhbnM9MjAiWiI9MjBk b24/PQogPT9VVEYtOD9xPz1FMj04MD05OXQ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ZSAob3IgbWludXRlIDApCiAg ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICA6c2Vjb25kIChvciBzZWNvbmQgMCkK KwkJCQkgOmRzdCAoaXNvODYwMS0tem9uZS1kc3Qgem9uZSkKICAgICAgICAgICAgICAgICAg ICAgICAgICAgICAgICAgIDp6b25lIChhbmQgem9uZQogICAgICAgICAgICAgICAgICAgICAg ICAgICAgICAgICAgICAgICAgICAgICAoKiA2MCAoaXNvODYwMS1wYXJzZS16b25lCiAgICAg ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB6b25lKSkp KSkpKSkpCkBAIC0zNjQsNyArMzcwLDcgQEAgaXNvODYwMS0tdmFsdWUKIAogKGNsLWRlZnVu IGlzbzg2MDEtLWRlY29kZWQtdGltZSAoJmtleSBzZWNvbmQgbWludXRlIGhvdXIKICAgICAg ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgZGF5IG1vbnRoIHllYXIKLSAgICAg ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgZHN0IHpvbmUpCisJCQkJICAgICAg KGRzdCAtMSkgem9uZSkKICAgKGxpc3QgKGlzbzg2MDEtLXZhbHVlIHNlY29uZCkKICAgICAg ICAgKGlzbzg2MDEtLXZhbHVlIG1pbnV0ZSkKICAgICAgICAgKGlzbzg2MDEtLXZhbHVlIGhv dXIpCkBAIC0zNzIsNyArMzc4LDcgQEAgaXNvODYwMS0tZGVjb2RlZC10aW1lCiAgICAgICAg IChpc284NjAxLS12YWx1ZSBtb250aCkKICAgICAgICAgKGlzbzg2MDEtLXZhbHVlIHllYXIp CiAgICAgICAgIG5pbAotCShpZiAob3IgZHN0IHpvbmUpIGRzdCAtMSkKKwlkc3QKICAgICAg ICAgem9uZSkpCiAKIChkZWZ1biBpc284NjAxLS1lbmNvZGUtdGltZSAodGltZSkKZGlmZiAt LWdpdCBhL3Rlc3QvbGlzcC9jYWxlbmRhci9pc284NjAxLXRlc3RzLmVsIG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gICAgICAnKDQ2IDI3IDE1IG5pbCBuaWwgbmlsIG5pbCAtMSAtMTgwMDAp KSkKICAgKHNob3VsZCAoZXF1YWwgKGlzbzg2MDEtcGFyc2UtdGltZSAiMTU6Mjc6NDYtMDUw MCIpCi0gICAgICAgICAgICAgICAgICcoNDYgMjcgMTUgbmlsIG5pbCBuaWwgbmlsIG5pbCAt MTgwMDApKSkKKyAgICAgICAgICAgICAgICAgJyg0NiAyNyAxNSBuaWwgbmlsIG5pbCBuaWwg LTEgLTE4MDAwKSkpCiAKICAgKHNob3VsZCAoZXF1YWwgKGlzbzg2MDEtcGFyc2UtdGltZSAi MTUyNzQ2LTA1IikKLSAgICAgICAgICAgICAgICAgJyg0NiAyNyAxNSBuaWwgbmlsIG5pbCBu aWwgbmlsIC0xODAwMCkpKQorICAgICAgICAgICAgICAgICAnKDQ2IDI3IDE1IG5pbCBuaWwg bmlsIG5pbCAtMSAtMTgwMDApKSkKICAgKHNob3VsZCAoZXF1YWwgKGlzbzg2MDEtcGFyc2Ut dGltZSAiMTU6Mjc6NDYtMDUiKQotICAgICAgICAgICAgICAgICAnKDQ2IDI3IDE1IG5pbCBu aWwgbmlsIG5pbCBuaWwgLTE4MDAwKSkpKQorICAgICAgICAgICAgICAgICAnKDQ2IDI3IDE1 IG5pbCBuaWwgbmlsIG5pbCAtMSAtMTgwMDApKSkpCiAKIAogKGRlZnVuIHRlc3QtaXNvODYw MS1mb3JtYXQtdGltZS1zdHJpbmctem9uZS1yb3VuZC10cmlwIChvZmZzZXQtbWludXRlcyB6 LWZvcm1hdCkKLS0gCjIuMzQuMQoK --------------JZDXFu3tBLNnmLSAz0gB1EW8 Content-Type: text/x-patch; charset=UTF-8; name="0003-Document-decoded-time-string-issue-on-6-elt-args.patch" Content-Disposition: attachment; filename*0="0003-Document-decoded-time-string-issue-on-6-elt-args.patch" Content-Transfer-Encoding: base64 RnJvbSA2M2RhOTM5YTdhZmFjMDU3NzVmNmM4MTgzZDU5YWI4Zjc4Y2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nZnVuY3Rpb24tZG9jdW1lbnRhdGlv bikKKyAgICAgICAgICAgICAiQXMgYSBzcGVjaWFsIGNhc2UsIGBkZWNvZGVkLXRpbWUtZHN0 JyByZXR1cm5zIGFuIHVuc3BlY2lmaWVkCit2YWx1ZSB3aGVuIGdpdmVuIGEgbGlzdCB0b28g c2hvcnQgdG8gaGF2ZSBhIGRzdCBlbGVtZW50LiIpKQorCiAoZGVmdW4gZ2V0LXNjcmF0Y2gt YnVmZmVyLWNyZWF0ZSAoKQogICAiUmV0dXJuIHRoZSAqc2NyYXRjaCogYnVmZmVyLCBjcmVh dGluZyBhIG5ldyBvbmUgaWYgbmVlZGVkLiIKICAgKG9yIChnZXQtYnVmZmVyICIqc2NyYXRj aCoiKQotLSAKMi4zNC4xCgo= --------------JZDXFu3tBLNnmLSAz0gB1EW8-- From debbugs-submit-bounces@debbugs.gnu.org Tue May 31 08:25:41 2022 Received: (at 55635-done) by debbugs.gnu.org; 31 May 2022 12:25:42 +0000 Received: from localhost ([127.0.0.1]:46939 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nw0wP-000680-B7 for submit@debbugs.gnu.org; Tue, 31 May 2022 08:25:41 -0400 Received: from mail-lj1-f172.google.com ([209.85.208.172]:45962) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nw0wN-00067l-JA for 55635-done@debbugs.gnu.org; Tue, 31 May 2022 08:25:40 -0400 Received: by mail-lj1-f172.google.com with SMTP id v9so14448022lja.12 for <55635-done@debbugs.gnu.org>; Tue, 31 May 2022 05:25:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:message-id:date:mime-version:user-agent:subject :content-language:to:cc:references:in-reply-to :content-transfer-encoding; bh=rnaosGgld+frQ5hiULFkCNSmMSN+xIVjyNv7fk/4yfw=; b=E4+PoAnp3dI5luv/u/pFKoMpPxt8sPWUIldPL8N9iaj7xhncWRxEYD/16Yiinh7Hkl 26G6nCvZJpYxmiv2RcolqppYq1zJnNrks6WveM9MSGYPS4tOUuLO0IDvRgug6It9UMVN yNycC5IoErN9G5JOtfAXmLVpd6fX2ocXcsIfkrRdfL1ARb5YEPhpVxhoLmRbvSnepg5m ff7H1cbfy2pUIoldaeB2e82sBWP9Zonrs3k1DlFvSZZSg7BFaRbmrxBBM/Tyg33A2vWG WyRvlRTvfD1Ccot5xbLbqADmUMiO0pj3DvdUh8Xz1AJpwjtG7aEGWFDzf6U29NqmKkbo NmVw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:message-id:date:mime-version:user-agent :subject:content-language:to:cc:references:in-reply-to :content-transfer-encoding; bh=rnaosGgld+frQ5hiULFkCNSmMSN+xIVjyNv7fk/4yfw=; b=40ffZ8R7GFLugcnidEQ9OhakeUgPZLJjudFlVTBNRaoZbsSM8dXg+IjlhhbypmAASG 4pmvRhWTJH1JSzcgzB2yPAZr//ggGrbhEqFmNlkSgXc34T5cv0KHaB351eOqs2Kx7DSR GgtdetuW7XImccYyTafe1Gjhsm7yCdk4GqcrN+7t+qKwsLnZDLOZDmt6IUx8sQsNvNuP KstrSgUwbjOXzd5QoBxAo3sGxSG8SXI7iTjOb6xjaMJ8BjJj6OjlYNZbwRxrB8Rhd8X3 TTDX7r/jB9bg49NCVgZgjmFpqODZTpa77LrlE3CeqKxts096zp+edmQvw4lEMhEB7+5c x/Sw== X-Gm-Message-State: AOAM533AJ87Zy25SFViV8TG9fJntBVlWJg+TbPPPYxDT2eQgS2NW7ryZ Jvro7wfWQptBj08SGH6Ja+k= X-Google-Smtp-Source: ABdhPJwRzOgs20ZfMcKkiehUXKOoECCPb1eSIsxvt8qh6x+EblpXRqwwhtafc9vJZRLA2xoz5yauUA== X-Received: by 2002:a2e:a4c7:0:b0:255:4dac:fe4c with SMTP id p7-20020a2ea4c7000000b002554dacfe4cmr7184984ljm.353.1653999933437; Tue, 31 May 2022 05:25:33 -0700 (PDT) Received: from [192.168.0.101] (nat-0-0.nsk.sibset.net. [5.44.169.188]) by smtp.googlemail.com with ESMTPSA id o16-20020ac24c50000000b0047255d2119bsm2932309lfk.202.2022.05.31.05.25.32 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 31 May 2022 05:25:32 -0700 (PDT) From: Maxim Nikulin X-Google-Original-From: Maxim Nikulin Message-ID: Date: Tue, 31 May 2022 19:25:25 +0700 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.9.1 Subject: Re: bug#55635: `make-decoded-time' incorrectly sets DST to nil, it should be -1 (guess) Content-Language: en-US To: Paul Eggert , Lars Ingebrigtsen References: <940415ce-2e31-ae18-3e16-8fdc54504a67@gmail.com> <87o7zkbif3.fsf@gnus.org> <96e9d729-2e23-5637-3136-ac29e26aa287@cs.ucla.edu> <87r14f8dhw.fsf@gnus.org> <87zgj23pn9.fsf@gnus.org> <0e506652-fb7d-5707-8247-7747ff1e53b0@gmail.com> <83o7zhlht0.fsf@gnu.org> <87sfos1o3o.fsf@gnus.org> <6ce0d14a-017c-2b28-d924-fb461396c547@cs.ucla.edu> In-Reply-To: <6ce0d14a-017c-2b28-d924-fb461396c547@cs.ucla.edu> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Spam-Score: -0.0 (/) X-Debbugs-Envelope-To: 55635-done Cc: Eli Zaretskii , 55635-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) On 30/05/2022 05:04, Paul Eggert wrote: > diff --git a/lisp/simple.el b/lisp/simple.el > index a254ee2251..d6b7045432 100644 > --- a/lisp/simple.el > +++ b/lisp/simple.el > @@ -10519,6 +10519,14 @@ capitalize-dwim > the number of seconds east of Greenwich.") > ) > > +;; Document that decoded-time-dst is problematic on 6-element lists. > +;; It should return -1 indicating unknown DST, but currently returns > +;; nil indicating standard time. > +(put 'decoded-time-dst 'function-documentation > + (append (get 'decoded-time-dst 'function-documentation) > + "As a special case, `decoded-time-dst' returns an unspecified > +value when given a list too short to have a dst element.")) > + Paul, thank you for your efforts to fix the issues. I have never used `cl-defstruct' before (and frankly speaking I am rather confused that the `decoded-time' struct and its constructor `make-decoded-time' are defined in different files and even directories are not the same), so my question may be naïve. Why did not you just add this new sentence to the :documentation property of the DST slot a bit above? By the way, after updating of `make-decoded-time', default value for DST should be updated in `cl-defstruct' as well, otherwise (describe-symbol 'decoded-time) reports that the default is nil. It may be reasonable to cross-link `decoded-time' and `make-decoded-time' in docstrings. Concerning timestamp vs. interval, first of all, I do not request immediate changes. I raised the question to make developers aware that the problem exist and it should be taken into account during further modifications or implementation of new features. Lars Ingebrigtsen, Sun, 29 May 2022 15:10:19 +0200. > If somebody wants to do > interval calculations and passes in a DST to make-decoded-time, that's a > classic "well, don't do that" situation. DST slot with -1 (default) value is rather confusing for intervals but it safer for timestamps. Certainly it possible to do anything with bytes in memory, but direction of programming languages and libraries development is to allow users to clearly express intentions code and to add some measures that prevents bugs. That is why I mentioned tagged structure for interval type to distinguish it from timestamps. Eli Zaretskii, Sat, 28 May 2022 19:53:47 +0300. >> From: Maxim Nikulin Date: Sat, 28 May 2022 23:31:43 +0700 >> >> I think, it is confusing that `make-decoded-time' is used to create >> timestamps *and* time intervals. They are different types, for example >> sum of intervals is meaningful (despite may be ambiguous) while there is >> no point to add timestamps. > > But this situation already exists with time units anyway. You can add > an hour to some other time, but there's also a valid time stamp that > expresses 1 hour past the epoch UTC, and their values are exactly > identical. Certainly timestamps are actually intervals with various reference points. Encoded time is counted from 1970, decoded time from 0 a.d., so trying to add the same timestamps you will get result depending on their representation. Decoded time in some cases is more convenient since 1 day may be not the same as 24 hours, not to mention varying duration of 1 month. The problem is that `decoded-time' time have field that are alien for intervals (timezone). Using the same constructor for both types makes code more obscure, it is impossible to enforce particular type of function argument to catch a programming error. It is possible to use the same type for timestamps and intervals further, I am trying to dispute that it is the best design choice. From debbugs-submit-bounces@debbugs.gnu.org Mon Jun 13 17:30:50 2022 Received: (at 55635) by debbugs.gnu.org; 13 Jun 2022 21:30:50 +0000 Received: from localhost ([127.0.0.1]:60638 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1o0re6-0006mI-A7 for submit@debbugs.gnu.org; Mon, 13 Jun 2022 17:30:50 -0400 Received: from zimbra.cs.ucla.edu ([131.179.128.68]:48520) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1o0re3-0006m2-FE for 55635@debbugs.gnu.org; Mon, 13 Jun 2022 17:30:49 -0400 Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id 00CAF1600FC; Mon, 13 Jun 2022 14:30:41 -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 O1HYcwA3xwlG; Mon, 13 Jun 2022 14:30:41 -0700 (PDT) Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id 02AA5160149; Mon, 13 Jun 2022 14:30:41 -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 hyeWC2pGDakR; Mon, 13 Jun 2022 14:30:40 -0700 (PDT) Received: from [192.168.1.9] (cpe-172-91-119-151.socal.res.rr.com [172.91.119.151]) by zimbra.cs.ucla.edu (Postfix) with ESMTPSA id C4C061600FC; Mon, 13 Jun 2022 14:30:40 -0700 (PDT) Content-Type: multipart/mixed; boundary="------------glXCi8ppBKeDYa6GnQauSDdj" Message-ID: <4ec38916-753e-be93-a08d-a4e7cc4dd86f@cs.ucla.edu> Date: Mon, 13 Jun 2022 14:30:40 -0700 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.9.1 Content-Language: en-US To: Maxim Nikulin References: <940415ce-2e31-ae18-3e16-8fdc54504a67@gmail.com> <87o7zkbif3.fsf@gnus.org> <96e9d729-2e23-5637-3136-ac29e26aa287@cs.ucla.edu> <87r14f8dhw.fsf@gnus.org> <87zgj23pn9.fsf@gnus.org> <0e506652-fb7d-5707-8247-7747ff1e53b0@gmail.com> <83o7zhlht0.fsf@gnu.org> <87sfos1o3o.fsf@gnus.org> <6ce0d14a-017c-2b28-d924-fb461396c547@cs.ucla.edu> From: Paul Eggert Organization: UCLA Computer Science Department Subject: Re: bug#55635: `make-decoded-time' incorrectly sets DST to nil, it should be -1 (guess) In-Reply-To: X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 55635 Cc: Eli Zaretskii , 55635@debbugs.gnu.org, Lars Ingebrigtsen X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) This is a multi-part message in MIME format. --------------glXCi8ppBKeDYa6GnQauSDdj Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: quoted-printable On 5/31/22 05:25, Maxim Nikulin wrote: > I have never used `cl-defstruct' before (and frankly speaking I am=20 > rather confused that the `decoded-time' struct and its constructor=20 > `make-decoded-time' are defined in different files and even directories= =20 > are not the same), so my question may be na=C3=AFve. Why did not you ju= st add=20 > this new sentence to the :documentation property of the DST slot a bit=20 > above? I am not sure I understand the question. The slot itself has a specified=20 value (t, nil, or -1) whereas the decoded-time-dst function returns an=20 unspecified value when there is no slot. > By the way, after updating of `make-decoded-time', default value for DS= T=20 > should be updated in `cl-defstruct' as well, otherwise > =C2=A0=C2=A0=C2=A0 (describe-symbol 'decoded-time) > reports that the default is nil. >=20 > It may be reasonable to cross-link `decoded-time' and=20 > `make-decoded-time' in docstrings. Thanks for the suggestions; I installed the attached. --------------glXCi8ppBKeDYa6GnQauSDdj Content-Type: text/x-patch; charset=UTF-8; name="0001-Default-decoded-time-dst-slot-to-1.patch" Content-Disposition: attachment; filename="0001-Default-decoded-time-dst-slot-to-1.patch" Content-Transfer-Encoding: base64 RnJvbSA1Njc4ODI5YTYyNzUyZWIzMzJjYWVmM2FiZWJlYjY0Y2IwNzIyNzA4IE1vbiBTZXAg MTcgMDA6MDA6MDAgMjAwMQpGcm9tOiBQYXVsIEVnZ2VydCA8ZWdnZXJ0QGNzLnVjbGEuZWR1 PgpEYXRlOiBNb24sIDEzIEp1biAyMDIyIDE0OjI1OjU4IC0wNzAwClN1YmplY3Q6IFtQQVRD SF0gRGVmYXVsdCBkZWNvZGVkLXRpbWUgZHN0IHNsb3QgdG8gLTEKCiogbGlzcC9zaW1wbGUu ZWwgKGRlY29kZWQtdGltZSk6IERlZmF1bHQgZHN0IHNsb3QgdG8gLTEuCkltcHJvdmUgcmVs YXRlZCBkb2Mgc3RyaW5ncy4KLS0tCiBsaXNwL2NhbGVuZGFyL3RpbWUtZGF0ZS5lbCB8ICAz ICsrLQogbGlzcC9zaW1wbGUuZWwgICAgICAgICAgICAgfCAxNiArKysrKysrKysrLS0tLS0t CiAyIGZpbGVzIGNoYW5nZWQsIDEyIGluc2VydGlvbnMoKyksIDcgZGVsZXRpb25zKC0pCgpk aWZmIC0tZ2l0IGEvbGlzcC9jYWxlbmRhci90aW1lLWRhdGUuZWwgYi9saXNwL2NhbGVuZGFy L3RpbWUtZGF0ZS5lbAppbmRleCA0MDM3NGMzYmI0Li5kMTkxMzRkYjgzIDEwMDY0NAotLS0g Y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NpYWwgY2FzZSwgYGRlY29kZWQtdGltZS1kc3Qn IHJldHVybnMgYW4gdW5zcGVjaWZpZWQKLXZhbHVlIHdoZW4gZ2l2ZW4gYSBsaXN0IHRvbyBz aG9ydCB0byBoYXZlIGEgZHN0IGVsZW1lbnQuIikpCisgICAgICJBY2Nlc3Mgc2xvdCBcImRz dFwiIG9mIGBkZWNvZGVkLXRpbWUnIHN0cnVjdCBDTC1YLgorVGhpcyBpcyB0IGlmIGRheWxp Z2h0IHNhdmluZyB0aW1lIGlzIGluIGVmZmVjdCwgbmlsIGlmIGl0IGlzIG5vdAoraW4gZWZm ZWN0LCBhbmQgLTEgaWYgZGF5bGlnaHQgc2F2aW5nIGluZm9ybWF0aW9uIGlzIG5vdCBhdmFp bGFibGUuCitBcyBhIHNwZWNpYWwgY2FzZSwgcmV0dXJuIGFuIHVuc3BlY2lmaWVkIHZhbHVl IHdoZW4gZ2l2ZW4gYSBsaXN0Cit0b28gc2hvcnQgdG8gaGF2ZSBhIGRzdCBlbGVtZW50Lgor CisoZm4gQ0wtWCkiKQogCiAoZGVmdW4gZ2V0LXNjcmF0Y2gtYnVmZmVyLWNyZWF0ZSAoKQog ICAiUmV0dXJuIHRoZSAqc2NyYXRjaCogYnVmZmVyLCBjcmVhdGluZyBhIG5ldyBvbmUgaWYg bmVlZGVkLiIKLS0gCjIuMzQuMQoK --------------glXCi8ppBKeDYa6GnQauSDdj-- From debbugs-submit-bounces@debbugs.gnu.org Tue Jun 14 11:58:02 2022 Received: (at 55635) by debbugs.gnu.org; 14 Jun 2022 15:58:02 +0000 Received: from localhost ([127.0.0.1]:35541 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1o18vZ-0000dR-Rc for submit@debbugs.gnu.org; Tue, 14 Jun 2022 11:58:02 -0400 Received: from mail-lf1-f54.google.com ([209.85.167.54]:36462) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1o18vW-0000ct-V2 for 55635@debbugs.gnu.org; Tue, 14 Jun 2022 11:57:59 -0400 Received: by mail-lf1-f54.google.com with SMTP id i29so14667580lfp.3 for <55635@debbugs.gnu.org>; Tue, 14 Jun 2022 08:57:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:message-id:date:mime-version:user-agent:subject :content-language:to:cc:references:in-reply-to :content-transfer-encoding; bh=xCN8AGTA5vLGXvn0ZUsQGyIIgJ3o+41C0tzfhDzU9zw=; b=EUhWnCnWQWnfAg/iZX7T96WXS512cMwFwzQ9rTzXEkWwUcRUbc1JHqrDSJ6lJOyJM9 D0JYzJUfb2BjUWfwNUYV0tMvvgNoucIrb92z+0T3NpICPk0rFQshujBID/TxTwMMDj2F W7cSgSPJQIGuE+A8qB5zLuXVUFWO8joc12IBilNdX6r5z8bGK6H8IjGZBy1M/WBmtP7T t/NxjGqoEGROE3lqIo+Sltmx5Ql1DhW632tiQAvgsEPavApPKixxe81irUHUfbgj3PEO 2bUOBo2TOXoI1x2rjs2j9VqE32o1YyvrPA4yurO9JCJw8yzIRjyk6wrsYNM2+D2hurIx XLNQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:message-id:date:mime-version:user-agent :subject:content-language:to:cc:references:in-reply-to :content-transfer-encoding; bh=xCN8AGTA5vLGXvn0ZUsQGyIIgJ3o+41C0tzfhDzU9zw=; b=vLO0oImnSfAJr4/CznodiX6bmwOcNJ7RcOwSkoJ9lo/VlxFOBux8afqv7Le5D02Occ TjqUHIoRC1Yr8jSs1Cr1yNGjepLctGvzOxtVO1Taj0n5BYa4YvrkPBCehFevu3lQW+XX ui8tgAbd6p+s7LyCVRlvyNbOrJ6tzYc7Fosd9iFDUv0xz9dkby+qQ/vrN4rUSVQd2vej Qxou/nrX15fyBYErrmm1krB8JxmojLQ23P9jsp5C3tWSHlRRDjqIM7CKuQbCqXn56jM/ ZYg1S0ML2L1hDDXzpavj1LrRP1wBxlXvnDLVTFpq43p5vfBWmn3zPOTuFgrLJPQ0fLSD h2Ng== X-Gm-Message-State: AJIora8RgQs1cnssIeVcI48KAjQznutmfL1p5RB4NxUAej6ChNzw2O5h vG8RwEp/EoLEJ55SVCHN1Ic= X-Google-Smtp-Source: AGRyM1v4N5I1P8Az4u3Mm68644XsQwYvxwYbsmuzsTOdpx5Bhaie585gBJ7RU0SlhTvFk/WpFszUvg== X-Received: by 2002:a05:6512:1329:b0:47d:c488:419b with SMTP id x41-20020a056512132900b0047dc488419bmr3595358lfu.398.1655222272654; Tue, 14 Jun 2022 08:57:52 -0700 (PDT) Received: from [192.168.0.101] (nat-0-0.nsk.sibset.net. [5.44.169.188]) by smtp.googlemail.com with ESMTPSA id g14-20020a2ea4ae000000b00256d361a6cbsm1409917ljm.9.2022.06.14.08.57.51 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 14 Jun 2022 08:57:52 -0700 (PDT) From: Maxim Nikulin X-Google-Original-From: Maxim Nikulin Message-ID: Date: Tue, 14 Jun 2022 22:57:51 +0700 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.9.1 Subject: Re: bug#55635: `make-decoded-time' incorrectly sets DST to nil, it should be -1 (guess) Content-Language: en-US To: Paul Eggert References: <940415ce-2e31-ae18-3e16-8fdc54504a67@gmail.com> <87o7zkbif3.fsf@gnus.org> <96e9d729-2e23-5637-3136-ac29e26aa287@cs.ucla.edu> <87r14f8dhw.fsf@gnus.org> <87zgj23pn9.fsf@gnus.org> <0e506652-fb7d-5707-8247-7747ff1e53b0@gmail.com> <83o7zhlht0.fsf@gnu.org> <87sfos1o3o.fsf@gnus.org> <6ce0d14a-017c-2b28-d924-fb461396c547@cs.ucla.edu> <4ec38916-753e-be93-a08d-a4e7cc4dd86f@cs.ucla.edu> In-Reply-To: <4ec38916-753e-be93-a08d-a4e7cc4dd86f@cs.ucla.edu> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Spam-Score: -0.0 (/) X-Debbugs-Envelope-To: 55635 Cc: Eli Zaretskii , 55635@debbugs.gnu.org, Lars Ingebrigtsen X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) On 14/06/2022 04:30, Paul Eggert wrote: > On 5/31/22 05:25, Maxim Nikulin wrote: > >> I have never used `cl-defstruct' before (and frankly speaking I am >> rather confused that the `decoded-time' struct and its constructor >> `make-decoded-time' are defined in different files and even >> directories are not the same), so my question may be naïve. Why did >> not you just add this new sentence to the :documentation property of >> the DST slot a bit above? > > I am not sure I understand the question. The slot itself has a specified > value (t, nil, or -1) whereas the decoded-time-dst function returns an > unspecified value when there is no slot. See the diff at the end of this message. Maybe I do not see any difference because I tried such definitions and (describe-function `decoded-time-dst), (describe-symbol 'decoded-time) in Emacs-27, not for the development version. >> It may be reasonable to cross-link `decoded-time' and >> `make-decoded-time' in docstrings. > > Thanks for the suggestions; I installed the attached. First of all, I am sorry, for some reason I missed that `make-decoded-time' already has "`decoded-time'" in its docstring. Maybe I am not familiar with help system enough, but my idea was to add a docstring to `cl-defstruct' as a whole (currently only slots are documented) that has "`make-decoded-time'" reference in the opposite direction to existing one. I admit that I missed something else and it is not necessary. diff --git a/lisp/simple.el b/lisp/simple.el index 99c951b24b..3054d79d44 100644 --- a/lisp/simple.el +++ b/lisp/simple.el @@ -10511,27 +10511,19 @@ This is an integer between 1 and 12 (inclusive). January is 1.") (year nil :documentation "This is a four digit integer.") (weekday nil :documentation "\ This is a number between 0 and 6, and 0 is Sunday.") + ;; decoded-time-dst is problematic on 6-element lists. + ;; It should return -1 indicating unknown DST, but currently returns + ;; nil indicating standard time. (dst -1 :documentation "\ This is t if daylight saving time is in effect, nil if it is not in effect, and -1 if daylight saving information is not available. -Also see `decoded-time-dst'.") +As a special case, return an unspecified value when given a list +too short to have a dst element.") (zone nil :documentation "\ This is an integer indicating the UTC offset in seconds, i.e., the number of seconds east of Greenwich.") ) -;; Document that decoded-time-dst is problematic on 6-element lists. -;; It should return -1 indicating unknown DST, but currently returns -;; nil indicating standard time. -(put 'decoded-time-dst 'function-documentation - "Access slot \"dst\" of `decoded-time' struct CL-X. -This is t if daylight saving time is in effect, nil if it is not -in effect, and -1 if daylight saving information is not available. -As a special case, return an unspecified value when given a list -too short to have a dst element. - -(fn CL-X)") - (defun get-scratch-buffer-create () "Return the *scratch* buffer, creating a new one if needed." (or (get-buffer "*scratch*") From unknown Wed Jun 18 00:26:49 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Wed, 13 Jul 2022 11:24:06 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator