From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: Declaring Lisp function types Date: Sun, 25 Feb 2024 19:15:08 +0200 Message-ID: <86il2cwjmr.fsf@gnu.org> References: Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="37394"; mail-complaints-to="usenet@ciao.gmane.io" Cc: acorallo@gnu.org, emacs-devel@gnu.org To: Alan Mackenzie Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Sun Feb 25 18:16:10 2024 Return-path: Envelope-to: ged-emacs-devel@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 1reI6j-0009VR-PI for ged-emacs-devel@m.gmane-mx.org; Sun, 25 Feb 2024 18:16:09 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1reI66-0001CJ-GZ; Sun, 25 Feb 2024 12:15:30 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1reI63-0001Bm-Id for emacs-devel@gnu.org; Sun, 25 Feb 2024 12:15:27 -0500 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1reI62-0003iB-S6; Sun, 25 Feb 2024 12:15:27 -0500 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=84hRyuRmxP/oY+y+ntNdfhya+/7wEsBC1cq+eQ01Lkk=; b=WYEweoUaFrkh 7ZUB5KqvZ50dOUsgwlI3dlUcwp4Fj9IpPP57SUHmGPs4H8YZRxm+KWVsK2UH9jFlVNumAe64roHkP jAngeFwOg2Mmmd12bAhaszWs4NawD2/SQXDaXhCMxH5tIjbaKr2RWWBz9OD0F/HHOMNMpjys+dlhu JeE1ynDLR145uNuY3Ski03cwZFVtZ3arKfO5S2ZjhLCxctk4GAGph1gUZMLCMT0TmHbTesZ1dqlAu veVT8dtwPP1EFFupYEkBOTnegP9wy81vbdcDC7U/ttIbMAGkU+X611iGbhK/lJtxiBpbfa9tNkQs2 Ek95y7ODY3Scv2i81giNgw==; In-Reply-To: (message from Alan Mackenzie on Sun, 25 Feb 2024 17:04:30 +0000) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:316533 Archived-At: > Date: Sun, 25 Feb 2024 17:04:30 +0000 > Cc: emacs-devel@gnu.org > From: Alan Mackenzie > > On Fri, Feb 23, 2024 at 11:02:52 -0500, Andrea Corallo wrote: > > Hi all, > > > I'm looking into moving out the function type declarations in > > 'comp-known-type-specifiers' in order to move them to where the function > > are actually defined. This to easy maintenance (ATM they get out of > > sync) and to allow the user for (indeed optionally) declaring function > > types. > > > In principle I believe we are interested in expressing the the argument > > types and (maybe optionally) the return type. > > What's missing is the why. Do we actually want to put function type > declarations in Lisp source at all? They will clutter up the code more > than it is cluttered up at the moment. My understanding of the rationale is that then we will be able to maintain the information about each function in one place, instead of in two. Currently, when the signature changes, someone must remember to go to that other place and update it. So I think this change is generally for the better, as it will make maintenance easier and less error-prone.