help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

reinventing the wheel but not faculty, libraries (was: Re: Indentation w


From: Emanuel Berg
Subject: reinventing the wheel but not faculty, libraries (was: Re: Indentation with spaces)
Date: Fri, 10 Jun 2022 12:29:23 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)

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




reply via email to

[Prev in Thread] Current Thread [Next in Thread]