From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Emanuel Berg Newsgroups: gmane.emacs.help Subject: reinventing the wheel but not faculty, libraries (was: Re: Indentation with spaces) Date: Fri, 10 Jun 2022 12:29:23 +0200 Message-ID: <875yl8lsl8.fsf_-_@dataswamp.org> References: <87fskezg7s.fsf@dataswamp.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="40066"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) To: help-gnu-emacs@gnu.org Cancel-Lock: sha1:ZQgqUjRFTDHTKFLaA5UTjmTUx4E= Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Fri Jun 10 13:18:28 2022 Return-path: Envelope-to: geh-help-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 1nzceo-000A85-Uc for geh-help-gnu-emacs@m.gmane-mx.org; Fri, 10 Jun 2022 13:18:26 +0200 Original-Received: from localhost ([::1]:59610 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nzcen-0004Cy-Am for geh-help-gnu-emacs@m.gmane-mx.org; Fri, 10 Jun 2022 07:18:25 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:38380) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nzbu2-0007FP-ID for help-gnu-emacs@gnu.org; Fri, 10 Jun 2022 06:30:12 -0400 Original-Received: from ciao.gmane.io ([116.202.254.214]:43470) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nzbu0-00058g-SZ for help-gnu-emacs@gnu.org; Fri, 10 Jun 2022 06:30:06 -0400 Original-Received: from list by ciao.gmane.io with local (Exim 4.92) (envelope-from ) id 1nzbtx-0007oz-Pk for help-gnu-emacs@gnu.org; Fri, 10 Jun 2022 12:30:01 +0200 X-Injected-Via-Gmane: http://gmane.org/ Mail-Followup-To: help-gnu-emacs@gnu.org Mail-Copies-To: never Received-SPF: pass client-ip=116.202.254.214; envelope-from=geh-help-gnu-emacs@m.gmane-mx.org; helo=ciao.gmane.io X-Spam_score_int: -16 X-Spam_score: -1.7 X-Spam_bar: - X-Spam_report: (-1.7 / 5.0 requ) BAYES_00=-1.9, HEADER_FROM_DIFFERENT_DOMAINS=0.249, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=no autolearn_force=no X-Spam_action: no action X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "help-gnu-emacs" Xref: news.gmane.io gmane.emacs.help:137605 Archived-At: Stefan Monnier via Users list for the GNU Emacs text editor wrote: >> Why is `indent-tabs-mode' t by default? Tabs should not >> be used. > > The world is split between 3 factions: > - those users who absolutely cannot tolerate TABs. > - those users who absolutely cannot tolerate the use of SPC instead of > TAB to indent. > - those users who have a life. I want official libraries with all small functions that don't change and that are possible to do in what would amount to an optimal way. We could start with a math library with stuff like this that I wrote just a couple of days ago. (defun faculty (n) (if (> n 1) (* n (faculty (1- n))) 1)) ;; (faculty 5) ; 120 ;; (faculty 10) ; 3 628 800 (defun cl-faculty (n) (cl-loop with prod = 1 for i from 2 to n do (setq prod (* i prod)) finally return prod) ) ;; (cl-faculty 5) ; 120 ;; (cl-faculty 10) ; 3 628 800 People say they don't want to reinvent the wheel. But that's wrong, that should actually be encouraged! You know how many wheels there are in industry, construction, transport, etc? They are the products of engineering and I'm sure in 100 years so many of them will have been improved, adapted, applied in new settings and so on compared to now. But math function and other simple but basic so very fundamental building blocks of software ... we should have killer libraries for that and in 100 years it'll be there for their convenience on whatever Lisp dialect they'll run so they can focus on improving the WHEELS! -- underground experts united https://dataswamp.org/~incal