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

Re: Is perl still the No.1 language for sysadmin?



On 4/2/23 10:14, Emanuel Berg wrote:
tomas wrote:

But Python's lambdas are preposterous (not so Perl's ;-)

Well, can't compare either to Lisp, the Pythagorean theorem of
computing ...


https://hop.perl.plover.com/

Preface

    Around 1993 I started reading books about Lisp, and I discovered
something important: Perl is much more like Lisp than it is like C. If
you pick up a good book about Lisp, there will be a section that
describes Lisp’s good features. For example, the book Paradigms of
Artificial Intelligence Programming, by Peter Norvig, includes a section
titled What Makes Lisp Different? that describes seven features of Lisp.
Perl shares six of these features; C shares none of them. These are big,
important features, features like first-class functions, dynamic access
to the symbol table, and automatic storage management. Lisp programmers
have been using these features since 1957. They know a lot about how to
use these language features in powerful ways. If Perl programmers can
find out the things that Lisp programmers already know, they will learn
a lot of things that will make their Perl programming jobs easier.


The one Lisp feature that is missing from (core) Perl is macros.


Using the techniques learned from HOP, I use higher order functions to substitute for macros.


Alternatively, there are macro modules available on CPAN:

https://metacpan.org/search?size=20&q=macro


David


Reply to: