4 ms·
"Bare bones" seems to be a good thing for Perl. I use Strawberry Perl on Windows and it is orders of magnitude faster than Powershell for processing large files
by wistlo 4y ago
"Bare bones" seems to be a good thing for Perl. I use Strawberry Perl on Windows and it is orders of magnitude faster than Powershell for processing large files of text strings using regular expressions.
I hope the addition of a "new object-oriented programming framework" won't take away the "bare-bones" speed of the current release.
- anthk 4y agoPerl's bindings for Win32 and OLE are amazing.
- csdvrx 4y agoWould you have some interesting examples? I love Win32 because it's the closest we have to a universal GUI format for software.
- anthk 4y agohttps://metacpan.org/pod/Win32::OLE https://metacpan.org/pod/Win32::OLE https://metacpan.org/pod/Win32 https://metacpan.org/pod/Win32 https://metacpan.org/search?size=20&q=win32 https://metacpan.org/search?size=20&q=win32
- jug 4y agoReally? This is interesting! I had completely written off Perl for Windows due to its heritage. But we still use COM objects in our scripts here and while I like PowerShell conceptually, I really never got to have fun with it as a scripting language. It just has so many quirks like “implicit returns” etc. and is just so verbose it’s bordering on hard to read at times.
- anthk 4y agohttps://metacpan.org/pod/Win32::OLE https://metacpan.org/pod/Win32::OLE https://metacpan.org/pod/Win32 https://metacpan.org/pod/Win32 https://metacpan.org/search?size=20&q=win32 https://metacpan.org/search?size=20&q=win32
- jandrese 4y agoWhile you can use them, I do not recommend it. The problem is when you want to convert a script into an EXE so not everybody has to install Strawberry Perl. Apparently some viruses are written in Perl because Windows Defender flags any exe you build as a virus and deletes it. Also, changing the application icon doesn't work, so you're always distributing a Camel app. It's a shame too because as you say the Win32 API stuff works great up until the antivirus kicks you in the nads.
- anthk 4y agoNot a Perl issue, but a Windows Defender one.
- jandrese 4y agoTrue, but people are going to be calling you, not Microsoft, when the app is instantly deleted when they download it. The worst part is that it isn't even consistent. It will be ok for a few months and then end up back on the virus list again.
- rurban 4y agoThe best OO frameworks Mouse and cperl make it faster. Moose, Moo and Corinna signicantly slower. Guess which frameworks are recommended
- justinator 4y agoCorinna is essentially the working spec of the new class system in Perl. I’m not sure being performant was ever the goal.
- cutler 4y agoI think this is where Ruby's reputation for being slow is a bit misleading. Perl is faster because it doesn't have OOP baked-in. Pre-load Moose and Perl's performance isn't that different than Ruby's.
- justinator 4y agoHonestly, I don't know, but I would assume Ruby's OO performance is better than Perl's with a very large extension (Moose), where some optimizations just aren't possible, given the core architecture of Perl, but I'm really getting above my pay grade in what I know about Perl internals (which is almost nothing, really, that's some scary looking stuff in there!). I do look forward to the new class system coming to Perl based on Corrina, but I also can't comment on how performant it's going to be, either. My guess is that going ahead on this large project was based on answers to questions like, "is it going to be more useful than Moose?" "More performant?" Because if not, why not just use Moose?
- cutler 4y agoDon't worry. The Perl community, which I love BTW, has bee fighting over Moose, Mouse, Moo and the inclusion of a Meta Object Protocol in the core since the mid-2000s which, I would argue is partly responsible for its decline. So for Perl OOP will always remain an option unless you count blessed hashrefs.