Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

More of my philosophy about Raku, formerly known as Perl6..

213 views
Skip to first unread message

Amine Moulay Ramdane

unread,
Mar 21, 2022, 4:44:30 PM3/21/22
to
Hello,



More of my philosophy about Raku, formerly known as Perl6..

I am a white arab from Morocco, and i think i am smart since i have also
invented many scalable algorithms and algorithms..


Raku, formerly known as Perl6, is a very interesting,
very powerful programming language that represents the
next evolution of Perl.

In my opinion, it fixes many of the problems with Perl5.
the features of Raru on their own are pretty compelling.

It has most of the features you would expect in most
modern programming languages:

Classes, first-class functions, asynchronous programming,
and all the normal structured programming stuff—in addition
to the normal Perl stuff with regular expressions and string manipulation.

However, it also has a lot of features that are not found
in many other languages, and certainly not usually in the same
one.

Optional typing. Similar to TypeScript or Julia, types may be declared, but are not required. Unlike Python, declared types will be enforced.

Pattern matching. Like Haskell, different function definitions can be defined for different input values.

Multiple dispatch. Like Julia or Common Lisp, different function bodies can be defined for different sets of argument types (a bit like pattern matching, but on types instead of values).

Lazily-generated sequences, like Haskell or Clojure.

Lisp-like AST macros.

Junctions—a feature unique to Raku as far as I know, but similar to
sum types (a.k.a. algebraic data types or variant types). However,
Junction types are more than merely a sum, and may include logical expressions in their definitions.

Built in syntax for defining grammars and generating parsers.

Raku is a weird confluence of Perl-like features and extremely sophisticated abstractions to come out of programming language research.

Raku is a language that has it all.

It somehow fits. Where Perl has always been the poster-child for dealing with patterns and strings, Raku extends ideas about patterns into other aspects of the language; The type system, function dispatches, and even to the code of the program itself. It’s almost as if the entire language is some kind of engine for reasoning about patterns—both textual and symbolic.

Python uses a global interpreter lock, you can't execute two threads at the same time. Raku, formerly known as Perl6, can.

Raku, formerly known as Perl6, has a great chance of adoption for a variety of reasons. There are no popular dynamic languages with a working concurrency model (I'm looking at you, GIL); Perl 6 has a working concurrency model. With Moore's law coming to an end,
this is a huge advantage. Further, it goes far beyond the primitive threads and locks which languages tend to offer.


I'd also point out that it has a very advanced OO model which pretty much leaves most competitors in the dust. On top of that, your classes have fewer lines of code and are easier to read.

I am also working with Raku, formerly known as Perl6, and i invite you
to download the following interesting book about Raku in a PDF format so that to learn it:

https://greenteapress.com/wp/think-perl-6/

And you can download the stable version of Raku, formerly known as Perl6, from the following website:

https://rakudo.org/


Thank you,
Amine Moulay Ramdane.



Bonita Montero

unread,
Mar 22, 2022, 9:56:17 AM3/22/22
to

Andrew Robinson

unread,
Jan 19, 2023, 8:13:23 PM1/19/23
to
From one Arab to another, greetings...

On Monday, March 21, 2022 at 4:44:30 PM UTC-4, Amine Moulay Ramdane wrote:
> Raku, formerly known as Perl6, is a very interesting, very powerful programming language that represents the next evolution of Perl.

I agree it is interesting, but I'm not sure it is an evolution: the fact you can't run Perl5 code (in the general case) under Perl6/Raku means Raku is a revolution. But that is a quibble.

I have been playing with Raku very part-time for about a week now, so I am by no means a Raku wonk. But I have noticed that Raku takes the inherent goofiness and idiosyncrasies of Perl and turns them up to 11.

Please don't be offended by this: coming from an IBM mainframe world and still facile with IBM z and IBM i, pretty much everything about the Unix-like side of the tracks is goofy and idiosyncratic. I like commands, language constructs, and coding practices that bespeak what they are, not some goofy metaphor the designer came up with, or someone's attempt to be concise through keyboard gymnastics.

[Plus the IBM mainframe was the first commercial virtualization platform, and still in many ways superior to its imitators such as VMWare, VirtualBox, qemu, KVM, etc., but that's another issue for another day]

Little about Raku is intuitive, simple, clean, or direct. The language trips over itself trying to do everything. I can't remember what reviewer called it "like Perl, a kitchen-sink language." You want a collection of items and counts of the appearance? Any other language does this by associative arrays, hashes, dicts, or objects. Raku does this with "Bag." Again, goofy. For one thing, nothing about a bag implies either order or the cardinality of the things in the bag.

I don't care that the metaphor predates Raku, it's still goofy

And let's just go berserk with operators, including those that can't be generated on a regular keyboard using the labelled keys and their shifts, alts, and options. Want to find out if one collection is a subset of another? Well, heaven forbid a .subset method! No, we are going to use ⊆ -- and for the most of the world who doesn't know what the Unicode sequence is, we offer a clunky alternative, (<=).

This is great for mathematicians and others who use those symbols on a daily basis, but for the rest of the world it's like an emoji factory gone haywire.

Sounds like I'm pretty down on Raku, doesn't it?

I'm not. In fact, I may be growing to love it. Because it is SO over-the-top goofy exaggerated, it is endearing. And when you say it offers everything you'd expect in a language, it offers a whole heck of a lot more than you find in base languages like Perl, Python, JavaScript, Ruby, Rexx, etc. (Rexx is me gratuitously throwing a mainframe language into the mix). Yeah, you can do all those things with libraries and extensions, but with Raku they are baked into the basic language.

The use of multi methods and subs is indeed very useful - something that Java programmers take for granted but which is very hard to do in most other language).

> It somehow fits. Where Perl has always been the poster-child for dealing with patterns and strings, Raku extends ideas about patterns into other
> aspects of the language; The type system, function dispatches, and even to the code of the program itself. It’s almost as if the entire language
> is some kind of engine for reasoning about patterns—both textual and symbolic.

I agree. It's twitty, but it works.

> I'd also point out that it has a very advanced OO model which pretty much leaves most competitors in the dust.

I dunno, Java's object model covers more ground than Raku and did it in the 1990s. But I agree the model is advanced and a lot better than similar languages, such as Perl5, Python, JavaScript, etc.

> On top of that, your classes have fewer lines of code and are easier to read.

You mention LISP (which really stands for "lots of insidious single parentheses"), have you ever used APL? I don't know if anyone has tried to impose object orientation on APL, but APL is the mother of all concise languages. It makes Perl and Raku look like COBOL.

I have been looking for analyses of Raku, and yours is one of the best I've found.

I think I might very well adopt Raku as my primary development language except for the fact that, as far as I know, it's not included in any distribution of any operating system. It's a chicken-and-egg situation for sure, but the language needs more penetration before I can justify making the leap.

But I would like to make the leap!
0 new messages