From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Lars Ingebrigtsen Newsgroups: gmane.emacs.bugs Subject: bug#55163: 29.0.50; master 4a1f69ebca (TICKS . HZ) for current-time broke lsp-mode Date: Fri, 29 Apr 2022 11:54:07 +0200 Message-ID: <878rroi5a8.fsf@gnus.org> References: <87sfpxxyvb.fsf@3-191.divsi.unimi.it> <87zgk5jtm6.fsf@gnus.org> <87o80kj2q1.fsf@gnus.org> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="9746"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) Cc: Vincenzo Pupillo , 55163@debbugs.gnu.org To: Paul Eggert Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Fri Apr 29 11:55:37 2022 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nkNLd-0002JA-AV for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 29 Apr 2022 11:55:37 +0200 Original-Received: from localhost ([::1]:42010 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nkNLb-0002Dt-RB for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 29 Apr 2022 05:55:35 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:55438) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nkNL4-0001m0-K9 for bug-gnu-emacs@gnu.org; Fri, 29 Apr 2022 05:55:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:56978) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nkNL4-0000sH-Al for bug-gnu-emacs@gnu.org; Fri, 29 Apr 2022 05:55:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1nkNL4-0005fI-58 for bug-gnu-emacs@gnu.org; Fri, 29 Apr 2022 05:55:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Lars Ingebrigtsen Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 29 Apr 2022 09:55:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 55163 X-GNU-PR-Package: emacs Original-Received: via spool by 55163-submit@debbugs.gnu.org id=B55163.165122606121721 (code B ref 55163); Fri, 29 Apr 2022 09:55:02 +0000 Original-Received: (at 55163) by debbugs.gnu.org; 29 Apr 2022 09:54:21 +0000 Original-Received: from localhost ([127.0.0.1]:50875 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nkNKO-0005eG-O0 for submit@debbugs.gnu.org; Fri, 29 Apr 2022 05:54:20 -0400 Original-Received: from quimby.gnus.org ([95.216.78.240]:35694) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nkNKN-0005e3-Ka for 55163@debbugs.gnu.org; Fri, 29 Apr 2022 05:54:20 -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=IX37SktNIo5GSqCLNRYOw0HzlmnfI9RP77KBMH9O35M=; b=ADuE8jaJo++KXYBD8uIYiuzlr0 R8/lI/nigF50M6bqmG6EmruLyXlmG6vpcI7xkEfvxoQcvgjX0rKevO8gLdxPyYexclMigyoajrahs UvqRdMxCHWis1hR4FoCkDsUhNY6PuhngoOzx6sH0Vw735zbSkr1BLAkGInXExA4+/FRE=; Original-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 1nkNKC-0004xk-2W; Fri, 29 Apr 2022 11:54:10 +0200 Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwAgMAAAAqbBEUAAAABGdBTUEAALGPC/xhBQAAACBj SFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAADFBMVEVMPz6tSELAp5r/ ///wg2LlAAAAAWJLR0QDEQxM8gAAAAd0SU1FB+YEHQktLqgXFxIAAAGdSURBVCjPRZHNatwwFIWP xNh0tHKHcRhm5ZYQEj+FYlIoWanFGmhW3TQkfgrHq5KVY0JoZ+UGzxDfp+yRXajA+H7cc390BAAL u61xASRwib6yhsAvnE/eO7sJUQJEnudmQRiq+BDgG0inPsi8L7Ew6PNZVm6YyXIzyZgyyP41KIHl f1nu2DqduqXldsinOc6XKWU5eqgAWalcFfaMXFpmu/1bAe4UIdr9vsK7FdYTOM7PcsrU2qKQMVzh Lqy+KDZNpn8w4jD1eiESLhfzdy0iQeGMSPN49hNxnUA+5yzVinkLqc9NvYaeamQ4N00rzZx5oywL 8ED4paVOpKvuFeFRy8Pd8WmJyOLlpchZ2i1hmDkyVOUr4TmAsg6dIPaES91adD1Swlj09KGDP/Go Dl9bwkcjR2YO07OsYhkiVAOWyXvoWEbgZqB1Cf50Mn6BPNvwYomWkQ1axdDhKb7cEYLDgNXKw3+f QWldQvX4EBJFbBLEY3rLIquDPycyZLBwzQzjVLOaQfoAeYDtXgZOpW9iUe0nZ+krjZNKpJ3h8Bfz d5OVvNxeIQAAACV0RVh0ZGF0ZTpjcmVhdGUAMjAyMi0wNC0yOVQwOTo0NTo0NiswMDowMPQctWcA AAAldEVYdGRhdGU6bW9kaWZ5ADIwMjItMDQtMjlUMDk6NDU6NDYrMDA6MDCFQQ3bAAAAAElFTkSu QmCC X-Now-Playing: Themselves's _CrownsDown_: "oversleeping" In-Reply-To: <87o80kj2q1.fsf@gnus.org> (Lars Ingebrigtsen's message of "Thu, 28 Apr 2022 23:51:50 +0200") X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:230931 Archived-At: Lars Ingebrigtsen writes: > Thanks; makes sense to me. And it was worth a try to modernise these > functions, but it doesn't seem like the world is ready yet (and it's > hard to see a practical way forward without deprecating all the current > time-related functions and creating new ones, which we probably don't > want to do). Thinking about this slightly more, perhaps it's worth doing? Because we currently have some interfaces in this area that could be more efficient or elegant. The time functions commonly used are don't have particularly discoverable names -- current-time and float-time are probably the ones used most. Another common source of times are (file-attribute-modification-time (file-attributes ...)), which is commonly called in loops, and generates a lot of unnecessary garbage. So perhaps we could come up with a set of new functions in this area that are more efficient and avoid using the old time formats. Off the top of my head, we could have (file-attribute file 'modification-time) (i.e., have a &rest to specify the attributes, and don't return a list if there's one attribute, which is common). And we could have `time' instead of `current-time', with (time 'float) instead of `float-time' and even (time 'decoded) instead of `decode-time'. Or `time-float', `time-decoded' with no parameters... And so on. That is, I think this might be an opportunity to overhaul Emacs in this area -- introduce efficient functions with consistent naming, and then obsolete the old ones after a while. -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no