×

Announcing: Slashdot Deals - Explore geek apps, games, gadgets and more. (what is this?)

Thank you!

We are sorry to see you leave - Beta is different and we value the time you took to try it out. Before you decide to go, please take a look at some value-adds for Beta and learn more about it. Thank you for reading Slashdot, and for making the site better!

Perl 5.20 Released, and Mojolicious 5.0: the Very Modern Perl Web Framework

Soulskill posted about 7 months ago | from the also-ready-for-prime-time dept.

Perl 126

Kvorg writes: "Back in 2012 Slashdot noticed how at the time of Perl 5.16, the modern Perl projects, including Mojolicious, formed a new and expanding movement of a Perl Renaissance. With the release of Perl 5.20 and Mojolicious 5.0, the Modern Perl Renaissance is ever more striking. Faster, neater, sharper with its asynchronous APIs, Mojolicious is extremely flexible with its advanced request routing, plugin system, perl templating and hook API. Its adherence to the modern interfaces and standards and its implementation of advanced features in support tools, DOM and CSS selectors makes it easy to program with.

Mojolicious, with its philosophy of optimized code-generation (think metaprogramming), enabled-by-default support for encodings and UTF-8, zero dependency deployment with wide support for existing CPAN packages, zero downtime restarts and fully tested implementations, reminds us of how fun and flexible programming in scripting languages used to be. Of course, integrated documentation and a very supportive bundled development server don't hurt, either. The new Perl release with new postfix dereference syntax, subroutine signatures, new slice syntax and numerous optimizations makes it all even more fun."

Sorry! There are no comments related to the filter you selected.

Damn I'm old... (5, Funny)

Penguinisto (415985) | about 7 months ago | (#47129197)

I kept thinking "I am the very model of a modern Major Perl Framework..."

Re:Damn I'm old... (1)

gstoddart (321705) | about 7 months ago | (#47129397)

LOL ...

I'm very well acquainted, too, with matters mathematical,
I understand equations, both the simple and quadratical,

Somewhat apropos, really.

Re:Damn I'm old... (1)

Talderas (1212466) | about 7 months ago | (#47131645)

About binomial theorem I'm teeming with a lot of news
With many cheerful facts about the square of the hypoteneus

Re:Damn I'm old... (2)

just_another_sean (919159) | about 7 months ago | (#47129529)

I think being old is a requirement for understanding TFS. :-)

Re:Damn I'm old... (4, Funny)

Tackhead (54550) | about 7 months ago | (#47130029)

I kept thinking "I am the very model of a modern Major Perl Framework..."

I am the very model of a modern Major Perl Framework,
But here I am on Slashdot, trying harder from my job to shirk,
From HackerNews to 4chan there's no forum in which I won't lurk,
I am the very model of a modern Major Perl Framework!

People still use Perl? (1, Informative)

Anonymous Coward | about 7 months ago | (#47129207)

Color me surprised.

Re: People still use Perl? (3, Funny)

thetoadwarrior (1268702) | about 7 months ago | (#47129249)

People still trotting out that tired meme? Color me surprised.

Re: People still use Perl? (1, Insightful)

Bill_the_Engineer (772575) | about 7 months ago | (#47129605)

You shouldn't be surprised by the inexperienced having all their attention taken by the shiny and new.

Re: People still use Perl? (0)

Anonymous Coward | about 7 months ago | (#47129863)

Be honest. You're not really surprised that someone brought that up.

Re:People still use Perl? (2)

Penguinisto (415985) | about 7 months ago | (#47129253)

People still use BASH (and yes, it's still hella usable if the task is simple).

If the tool fits and does the job, use it.

Re:People still use Perl? (-1)

Anonymous Coward | about 7 months ago | (#47129621)

Damn straight... And it shouldn't matter if you use A# .NET, A# (Axiom), A-0 System, A+, A++, ABAP, ABC, ABC ALGOL, ABLE, ABSET, ABSYS, ACC, Accent, Ace DASL, ACL2, ACT-III, Action!, ActionScript, Ada, Adenine, Agda, Agilent VEE, Agora, AIMMS, Alef, ALF, ALGOL 58, ALGOL 60, ALGOL 68, ALGOL W, Alice, Alma-0, AmbientTalk, Amiga E, AMOS, AMPL, APL, AppleScript, Arc, ARexx, Argus, AspectJ, Assembly, ATS, Ateji PX, AutoHotkey, Autocoder, AutoIt, AutoLISP / Visual LISP, Averest, AWK, AxumBB, Babbage, BAIL, Bash, BASIC, bc, BCPL, BeanShell, Batch (Windows/Dos), Bertrand, BETA, Bigwig, Bistro, BitC, BLISS, Blue, Bon, Boo, Boomerang, Bourne shell (including bash and ksh), BREW, BPEL, BuildProfessionalCC, C--, C++ - ISO/IEC 14882, C# - ISO/IEC 23270, C/AL, Caché ObjectScript, C Shell, Caml, Candle, Cayenne, CDuce, Cecil, Cel, Cesil, Ceylon, CFML, Cg, Ch, Chapel, CHAIN, Charity, Charm, Chef, CHILL, CHIP-8, chomski, ChucK, CICS, Cilk, CL (IBM), Claire, Clarion, Clean, Clipper, CLIST, Clojure, CLU, CMS-2, COBOL - ISO/IEC 1989, Cobra, CODE, CoffeeScript, Cola, ColdC, ColdFusion, CoolCOMAL, Combined Programming Language (CPL), Common Intermediate Language (CIL), Common Lisp (also known as CL), COMPASS, Component Pascal, COMIT, Constraint Handling Rules (CHR), Converge, Coral 66, Corn, CorVision, Coq, COWSEL, CPL, csh, CSP, Csound, Curl, Curry, Cyclone, CythonDD, DASL (Datapoint's Advanced Systems Language), DASL (Distributed Application Specification Language), Dart, DataFlex, Datalog, DATATRIEVE, dBase, dc, DCL, Deesel (formerly G), DelphiDCL, DinkC, DIBOL, Dog, Draco, DRAKON, Dylan, DYNAMOEE, E#, Ease, Easy PL/I, EASYTRIEVE PLUS, ECMAScript, Edinburgh IMP, EGL, EiffelELAN, Elixir, Elm, Emacs Lisp, Emerald, Epigram, Erlang, es, Escapade, EscherESPOL, Esterel, Etoys, Euclid, Euler, Euphoria, EusLisp Robot Programming Language, CMS EXEC, EXEC 2, Executable , UMLFF, F#, Factor, Falcon, Fancy, Fantom, FAUST, Felix, Ferite, FFP, Fjölnir, FL, Flavors, Flex, FLOW-MATIC, FOCAL, FOCUS, FOIL, FORMAC, @Formula, Forth, Fortran - ISO/IEC 1539, Fortress, FoxBase, FoxPro, FP, FPr, Franz Lisp, F-Script, FSProgGG, Game Maker Language, GameMonkey Script, GAMS, GAP, G-code, Genie, GDL, GibianeGJ, GEORGE, GLSL, GNU E, GM, Go, Go!, GOAL, Gödel, Godiva, GOM (Good Old Mad), Goo, Gosu, GOTRAN, GPSS, GraphTalk, GRASS, GroovyHHack (programming language), HAL/S, Hamilton C shell, Harbour, Hartmann pipelines, HaskellHaxe, High Level Assembly, HLSL, Hop, Hope, Hugo, Hume, HyperTalkIIBM Basic assembly language, IBM HAScript, IBM Informix-4GL, IBM RPG, ICI, Icon, Id, IDL, Idris, IMP, Inform, Io, Ioke, IPL, IPTSCRAE, ISLISP, ISPF, ISWIMJJ, J#, J++, JADE, Jako, JAL, Janus, JASS, Java, JavaScript, JCL, JEAN, Join Java, JOSS, Joule, JOVIAL, Joy, JScript, JScript .NET, JavaFX Script, JuliaKK, Kaleidoscope, Karel, Karel++, KEE, KIF, Kojo, Kotlin, KRC, KRL, KRL (KUKA Robot Language), KRYPTON, kshLL, L# .NET, LabVIEW, Ladder, Lagoona, LANSA, Lasso, LaTeX, Lava, LC-3, Leadwerks Script, Leda, Legoscript, LIL, LilyPond, Limbo, Limnor, LINC, Lingo, Linoleum, LIS, LISA, Lisaac, Lisp - ISO/IEC 13816, Lite-CLithe, Little b, Logo, Logtalk, LPC, LSE, LSL, LiveCode, LiveScript, Lua, Lucid, Lustre, LYaPAS, LynxMM, M2001, M4, Machine code, MAD (Michigan Algorithm Decoder), MAD/I, Magik, Magma, make, Maple, MAPPER (Unisys/Sperry) now part of BIS, MARK-IV (Sterling/Informatics) now VISION:BUILDER of CA, Mary, MASM Microsoft Assembly x86, Mathematica, MATLABMaxima (see also Macsyma), Max (Max Msp - Graphical Programming Environment), MaxScript internal language 3D Studio Max, Maya (MEL), MDL, Mercury, Mesa, Metacard, Metafont, MetaL, Microcode, MicroScript, MIIS, MillScript, MIMIC, Mirah, MirandaMIVA Script, ML, Moby, Model 204, Modelica, Modula, Modula-2, Modula-3, Mohol, MOO, Mortran, Mouse, MPD, MSIL - deprecated name for CIL, MSL, MUMPSNNASM, NATURAL, Napier88, Neko, Nemerle, nesC, NESL, Net.Data, NetLogoNetRexx, NewLISP, NEWP, Newspeak, NewtonScript, NGL, Nial, Nice, Nickle, NPL, Not eXactly C (NXC), Not Quite C (NQC), NSIS, Nu, NWScriptOo:XML, Oak, Oberon, Obix, OBJ2, Object Lisp, ObjectLOGO, Object REXX, Object Pascal, Objective-C, Objective-J, Obliq, Obol, OCaml, occam, occam-, Octave, OmniMark, Onyx, Opa, Opal, OpenEdge ABL, OPL, OPS5, OptimJ, Orc, ORCA/Modula-2, Oriel, Orwell, Oxygene, OzPP#, PARI/GP, Pascal - ISO 7185, Pawn, PCASTL, PCF, PEARL, PeopleCode, Perl, PDL, PHP, Phrogram, Pico, Pict, Pike, PIKT, PILOT, Pipelines, Pizza, PL-11, PL/0, PL/B, PL/C, PL/I - ISO 6160, PL/M, PL/P, PL/SQL, PL360, PLANC, Plankalkül, PLEX, PLEXIL, Plus, POP-11, PostScript, PortablE, Powerhouse, PowerBuilder - 4GL GUI appl. generator from Sybase, PowerShell, PPL, Premise, Processing, Processing.js, Prograph, PROIV, Prolog, Visual Prolog, Promela, PROSE modeling language, PROTEL, ProvideX, Pro*C, Pure, PythonQQ (equational programming language), Q (programming language from Kx Systems), QalbQi, QtScript, QuakeC, QPLRR, R++, Racket, RAPID, Rapira, Ratfiv, Ratforrc, REBOL, Red, Redcode, REFAL, Reia, Revolution, rex, REXX, Rlab, RobotC, ROOP, RPG, RPL, RSL, RTL/2, Ruby, RustSS, S2, S3, S-Lang, S-PLUS, SA-C, SabreTalk, SAIL, SALSA, SAM76, SAS, SASL, Sather, Sawzall, SBL, Scala, Scheme, Scilab, Scratch, Script.NET, Sed, Seed7, Self, SenseTalk, SequenceL, SETL, Shift Script, SIMPOL, SIMSCRIPT, Simula, Simulink, SISAL, SLIP, SMALL, Smalltalk, Small Basic, SML, SNOBOL(SPITBOL), Snowball, SOL, Span, SPARK, SPIN, SP/k, SPS, Squeak, Squirrel, SR, S/SL, Starlogo, Strand, Stata, Stateflow, Subtext, SuperCollider, SuperTalk, SYMPL, SyncCharts, SystemVerilogTT, TACL, TACPOL, TADS, TAL, Tcl, Tea, TECO, TELCOMPTeX, TEX, TIE, Timber, TMG, compiler-compiler, Tom, TOM, Topspeed, TPU, Trac, TTM, T-SQL, TTCN, Turing, TUTOR, TXL, TypeScript, Turbo C++UUbercode, UCSD Pascal, UmpleUnicon, Uniface, UNITYUnix shell, UnrealScriptVVala, VBA, VBScript, Verilog, VHDL, Visual BasicVisual Basic .NET, Microsoft Visual C++, Visual C#, Visual DataFlex, Visual DialogScript, Visual Fortran, Visual FoxProVisual J++, Visual J#, Visual Objects, VSXu, Vvvv, WWATFIV, WATFOR, WebDNAWebQL, Windows PowerShell, WinbatchXX++, X#, X10, XBL, XC (exploits XMOS architecture)xHarbour, XL, Xojo, XOTcl, XPL, XPL0, XQuery, XSB, XSLT - See XPathYYorickYQL, ZZ notation, Zeno, ZOPL, ZPL

Re:People still use Perl? (0)

Anonymous Coward | about 7 months ago | (#47129647)

Hey I remember programming in CHILL. For the curious I worked with the Germans not the Canadains. I think only two companies ever used CHILL for anything real.

Re:People still use Perl? (1)

HeckRuler (1369601) | about 7 months ago | (#47130629)

I was going to comment how you skipped Malbolge and how that makes you a closed-minded noob that only works with popular languages, but then I noticed that you skipped over C. Or maybe you made a typo and lumped it with BuildProfessionalCC.

So if you were wondering why you got skipped over a job, it might just be because HR's filter didn't think you knew how to program in C.

Re:People still use Perl? (1)

Molt (116343) | about 7 months ago | (#47130949)

People still use C? Really?

Re:People still use Perl? (1)

HeckRuler (1369601) | about 7 months ago | (#47131519)

Yeah, it's pretty popular in the embedded world. Toasters, Arduinos, Avionics.

When the hardware maker couldn't be bothered to make a high level compiler for the chip or when the thing absolutely positively can't be allowed to fail, C is a good choice.

Oh, and that Linux thing and a large swath of open source software. You know, if you're into that sort of thing.

Re:People still use Perl? (1)

TechyImmigrant (175943) | about 7 months ago | (#47129833)

Perl is monochrome.

Re:People still use Perl? (0)

Anonymous Coward | about 7 months ago | (#47129937)

Perl is monochrome.

So are all my SSH sessions (and my two surviving VT-220's and a Televideo 910). Either I don't get the term or fail to see what color has to do with anything. Now get off my lawn!

Re:People still use Perl? (1)

TechyImmigrant (175943) | about 7 months ago | (#47130343)

What PERL looks like to Python programmers..

http://www.google.com/imgres?i... [google.com]

What Python looks like to Perl programmers (3, Funny)

raymorris (2726007) | about 7 months ago | (#47130927)

http://handsonaswegrow.com/wp-... [handsonaswegrow.com]

Not exactly, but I like the picture.

Awesome! (5, Interesting)

just_another_sean (919159) | about 7 months ago | (#47129213)

I don't much care about what a lot of people think about it, I love Perl and still use it daily in my job. I've dabbled in PHP and the various frameworks it supports but I always find myself returning to Perl/CGI/DBI. But this sounds like something I have been waiting for. It's really nice to see some new stuff coming out for Perl 5 as I simply can't seem to wrap my head around Perl 6. This is great news for old dogs!

Maybe one day (2)

aliquis (678370) | about 7 months ago | (#47129345)

Maybe one day even Slashdot will get UTF-8 support.

One day.

Any decade now.

Re:Maybe one day (1)

larry bagina (561269) | about 7 months ago | (#47129861)

Huh? Still no UTF-8 support? Damn. A couple years ago they hired a hotshot perl programmer with 30 years of UTF-8 experience to implement it. Hired him off Dice.com, in fact. Oh, hmmm. Well, ASCII is good enough.

Re:Maybe one day (0)

Anonymous Coward | about 7 months ago | (#47130143)

It almost sounds as if Dice.com assisted in taking money from Slashdot without offering anything in return. But hey, at least they gave us Beta.

Re:Maybe one day (0)

Anonymous Coward | about 7 months ago | (#47130693)

Maybe Beta have UTF-8 support?

Of course we'll never know SINCE NOONE IS USING THAT SHIT.

(Also I'm quite sure it doesn't. I actually recommended that as a better new Slashdot than Beta. Simply the same Slashdot but with UTF-8 support. Great. They may have made a new super ugly blog called Slashdot Beta and then forgot about UTF-8 support for another 20 years.)

Re:Maybe one day (0)

Anonymous Coward | about 7 months ago | (#47131091)

Maybe Beta have UTF-8 support?

Of course we'll never know SINCE NOONE IS USING THAT SHIT.

(Also I'm quite sure it doesn't. I actually recommended that as a better new Slashdot than Beta. Simply the same Slashdot but with UTF-8 support. Great. They may have made a new super ugly blog called Slashdot Beta and then forgot about UTF-8 support for another 20 years.)

I'm using Slahdot Beta, and:

From the source code:

        Perl 5.20 Released, and Mojolicious 5.0: the Very Modern Perl Web Framework - Slashdot

[snip]

     

Re:Maybe one day (0)

Anonymous Coward | about 7 months ago | (#47131121)

Fixed:

!DOCTYPE html
html lang="en"
head

        title Perl 5.20 Released, and Mojolicious 5.0: the Very Modern Perl Web Framework - Slashdot /title

[snip]

        meta http-equiv="Content-Type" content="text/html; charset=utf-8"

That's not it (1)

shiftless (410350) | about 7 months ago | (#47132277)

UTF-8 support doesn't mean what the XML/HTML contains. It means what characters can you post on here without it getting fucked up by slashdot. So those of you whose eyes were plucked out by ravens and now use a text-to-speech interpreter to use the Beta site--do you see this? UTF-8 characters follow:

That's not it (0)

Anonymous Coward | about 7 months ago | (#47133323)

No I don't see any character.

Re:Awesome! (4, Interesting)

walkeraj (1234310) | about 7 months ago | (#47129745)

Perl 6, what's that? Seriously though, it's nice to see p5 undergoing productive changes as the grand wait for Perl 6 wears on and as it becomes more clear that the Perl 6 we're getting might not be the one we wanted. Having said that, I find it annoying that the focus on backwards compatibility hamstrings new features to the degree that everything is marked as unstable or experimental and we're left just writing the same damn old perl 5 we've been writing for years. We keep dancing around the issue, but what's really needed is a breaking fork of p5 to revamp the code base and remove a lot of the cruft and make a language that can be parsed by more than just the perl interpreter. Better packaging would be nice too. I'd love to see Perl offer proper bundled binaries a la Go.

Re:Awesome! (3, Informative)

preaction (1526109) | about 7 months ago | (#47130149)

The p5p (Perl 5 Porters, the main p5 dev group) are removing a bunch of cruft. Old OSes and EBCDIC are up on the chopping block next. They're also removing microperl, which unfortunately probably is the best chance of getting more than perl to parse Perl (microperl removes just about every OS-specific function of Perl, like the unix user/group/passwd file stuff).

But honestly, there's so few people working in the core code, and I don't imagine any of the major forks I've heard about gaining any steam either.

Re:Awesome! (0)

walkeraj (1234310) | about 7 months ago | (#47132063)

Yeah, and what I'm talking about is ditching stuff like perlform, unless and statement modifiers, and incorporating a decent objective framework like MOP into core itself. A big job, and, like you say, probably not a lot of people willing to do it. Might as well reimplement.

Re:Awesome! (1)

Anonymous Coward | about 7 months ago | (#47132177)

Yeah, and what I'm talking about is ditching stuff like [...] unless and statement modifiers

FOAD

Re:Awesome! (2)

nmr_andrew (1997772) | about 7 months ago | (#47131241)

More than likely, I don't expect Perl 6 to ever see light of day. The big problem with it is that it's not Perl.

I don't have a huge problem with a new scripting language, but recognize that it's (for all useful purposes) something new and different and give the project a new name. Also, Perl 5 is AFAICT completely backwards compatible to at least Perl 3; Perl 6 either won't run prior code or requires a huge hack to do so.

Re:Awesome! (1)

walkeraj (1234310) | about 7 months ago | (#47131457)

Absolutely. I was a big proponent of a new name (and a better logo http://wirespeed.wordpress.com... [wordpress.com] ), but I don't see that changing. Which is sad, because the lack of solid branding has always been one of its biggest problems. :(

Re: Awesome! (2)

jd2112 (1535857) | about 7 months ago | (#47132685)

Perl 6 is the language of the future and always will be.

asynchronious APIs! (0)

Anonymous Coward | about 7 months ago | (#47129243)

There is no "i" (nor "me") in asynchronous.

Pearl and Modern in the Same sentence? (-1)

Anonymous Coward | about 7 months ago | (#47129379)

Don't make me laugh

Re:Pearl and Modern in the Same sentence? (0)

Anonymous Coward | about 7 months ago | (#47129883)

Objective-C is older and it's usually considered as fairly modern.

That's not it. (1)

fyngyrz (762201) | about 7 months ago | (#47131041)

The problem isn't that perl is old. The problem is that perl reads (and writes) like encrypted sanskrit and is just generally weird in its approach to everything.

Once you've invested a great deal of time learning it, and its APIs, it's a big deal to change, because you're effective in it... but, speaking from personal experience, after years of perl-ing, I tried something else, and what a revelation it was. Not everyone is willing to put in the kind of effort it takes, and familiarity itself can make nice seem wrongish after years of coding otherwise.

For new entries to the scripting language world, the only really good reason to learn perl is to maintain legacy code. Updates can't fix it -- the very language is a mess. And the fact is, there are some really terrific scripting languages out there now. There's little -- or no -- need to subject one's self to perl.

Re:That's not it. (2)

preaction (1526109) | about 7 months ago | (#47131187)

I disagree, but perhaps that is because I learned how to program by learning Perl. I've written huge projects in Python, C++, Java, and JavaScript, and I still prefer Perl for my daily problems (but then, I also actually like C++, so it is possible that I am irreparably damaged). I have had no problem moving to other languages, I even like what they offer (even Java).

Python's idea of the ternary operator, now that's weird. STRING.join( ITERABLE ), that's weird (though the only obvious solution because of how Python is). `string + number = string concatenation`, that's weird. There's weirdness all around!

Re:That's not it. (1)

guacamole (24270) | about 7 months ago | (#47131271)

Perl was designed by people and for people who were fond of the Unix shell scripting syntax, all the unix tools, and the C language, which were the primary tools of coding unix in the old days. Unfortunately, Perl looks cryptic to anyone without a background in that sort of Unix environment. Most people don't learn unix shell scripting and C, before jumping into a scripting programming language. They jump straight into scripting language. As a result, Python has a huge advantage with this crowd. Then there is the issue of TMTOWTDI, which a lot of companies and programmers want to avoid these days.

Re:That's not it. (1)

preaction (1526109) | about 7 months ago | (#47131331)

To this day I'm surprised at how much the shell can do for me, and I spend most of my time there. I find myself writing fewer Perl scripts and more shell scripts to Get Stuff Done.

I've kept saying "Perl is the UNIX philosophy taken beyond its logical conclusion."

Re:That's not it. (1)

kthreadd (1558445) | about 7 months ago | (#47131517)

Shell scripting usually works fine until you want to 1. be portable or 2. work with strings. You can do both with shell but I usually go with something like Perl when it happens.

Re:That's not it. (2)

preaction (1526109) | about 7 months ago | (#47131543)

Shell has marginally better whipituptitude, until you want

1) Arrays
2) Deep string operations
3) Documents

(though, side note, I'm working on a project to make (3) easier to handle because it comes up so often, and there's jq already)

Re:That's not it. (5, Insightful)

nmr_andrew (1997772) | about 7 months ago | (#47131349)

The problem isn't that perl is old. The problem is that perl reads (and writes) like encrypted sanskrit...

I really wish people would stop saying this. It's certainly possible to write horribly obfuscated Perl, deliberately or otherwise, just as it's possible to write C, or Python, or anything else in a nearly unreadable way. I'll grant that Perl maybe allows you to get away with a bit more.

However, it's just about as easy to write clean, maintainable Perl as it is in any other language. Follow good coding practices and you'll have clean code, code badly and it'll be a train wreck regardless of language.

Re:That's not it. (0)

Anonymous Coward | about 7 months ago | (#47131531)

You can't write bad code in Python because Python forces you to use consistent indentation.

Re:That's not it. (5, Interesting)

Anonymous Coward | about 7 months ago | (#47132963)

To expound on this point a bit deeper:

While one can write horrible code (without trying too hard) in any language (even python!), there *is* a rational reason that Perl tends to fare worse in this regard on average.

The reason is that, as compared to almost every other programming language out there, Perl was designed by a Linguist (as in, human languages) with an explicit goal of being very expressive. In many other languages, there's one canonical way to do a given thing, and then perhaps a few other ugly, horrible, slow, round-about ways to accomplish the same thing different, but most of the time everyone hones in on the same approximate language patterns.

Perl, on the other hand, was explicitly designed such that there are often many wildly varying different ways to accomplish the same goal, allowing for a great freedom of expression and stylistic choice. Over the years this theme has extended throughout the Perl ecosphere, well beyond the syntactic features of the core language itself, to the point that just about any programming style or paradigm can be wrought within Perl easily. Do you like C++-style multiple inheritance? Or maybe something more like Traits/Roles and object method invocation via message passing? How about functional style lamba stuff? Meta-object programming? Threads (of a few kinds), Processes, eventloops (of many kinds)? Declarative programming (with or without OO)? DSLs? How many flavors of templating do you want? Just about any real or academic-toy knob you can think of to twist which would affect how programming languages work probably already exists within Perl at this point. In this way it's almost like a modern LISP, but with a much larger standard library of language tools built on top, and fewer parentheses.

So you throw 50 "professional" programmers in a room with a Perl interpreter and ask them to solve the same high-level problem and you'll probably get 45 completely shitty implementations, 3 decent ones, and two brilliant ones. But not a single one of those 50 implementations will resemble the others much.

In the hands of a real artist, Perl is a very powerful tool for writing beautiful software, and it gives said artist the freedom to solve problems using the paradigms and syntactic styles that best match the problem domain without ever leaving the world of Perl. In the hands of a novice, however, it's way too much expressive freedom, and leads to basically-trashy, horrible code. Perl is programming without lane markers, seat belts, or brakes. There's nothing standing in the way of greatness, and nothing standing in the way of being a complete idiot, either.

Unfortunately, most programmers in the world aren't artists. They lack the innate skill, the drive and determination, or even the desire to become an artist. They're just doing a job and collecting a paycheck. Python is a great tool for these people, and Perl is not.

Mod parent up (1)

rduke15 (721841) | about 7 months ago | (#47133403)

Someone please mod parent up...

Re:That's not it. (1)

Raenex (947668) | about 7 months ago | (#47133727)

I really wish people would stop saying this. It's certainly possible to write horribly obfuscated Perl, deliberately or otherwise, just as it's possible to write C, or Python, or anything else in a nearly unreadable way. I'll grant that Perl maybe allows you to get away with a bit more.

I really wish people would stop defending Perl in the manner. Perl's sigil madness is endemic to the language. Yes, you can avoid some of the craziness (such as "use English"), but good luck to you once you start using references.

Bah (1)

93 Escort Wagon (326346) | about 7 months ago | (#47129423)

I was using perl before it was cool.

(I figured a fanboi submission required a hipster response)

Re:Bah (0)

Anonymous Coward | about 7 months ago | (#47129915)

That's more of a curmudgeon response.

A hipster response would tell us you're using something we've never heard of.
You get bonus points if it's "organic", "hand made", or "limited release", and it's made by a bearded man in a Williamsburg loft.

Re:Bah (0)

CaptSlaq (1491233) | about 7 months ago | (#47131073)

I was using perl before it was cool.

(I figured a fanboi submission required a hipster response)

Perl was cool? Seems that it's never been since I started using it in 2000.

A language that lets you do whatever (4, Insightful)

duckgod (2664193) | about 7 months ago | (#47129677)

The thing that I have always loved about perl is the "there's more than one way to do it" philosophy. Perl lets me do whatever the fuck I want. If I am doing a project for my own enjoyment then I will do whatever I want that gets the job done the fastest. Yes maybe this makes it a bad language for large groups and production applications where programmers need to have restraints in order for the group to work harmoniously. But I am an adult and I don't want to be told what is right or wrong way to do something in my home.

Re:A language that lets you do whatever (4, Interesting)

Anonymous Coward | about 7 months ago | (#47131059)

That's one side of perl: The fastest development time imaginable for small programs. The other side, that no one has mentioned, is that perl conforms to the OO paradigm more closely than any other language (including Objective-C.) I have written very large programs in perl and contrary to popular opinion these programs are much easier to read and understand than if they were written in C++ for example.

Re:A language that lets you do whatever (0)

mooingyak (720677) | about 7 months ago | (#47133055)

The other side, that no one has mentioned, is that perl conforms to the OO paradigm more closely than any other language

Except for nearly all of the other ones? Especially other scripting languages?

Pick a bunch of languages at random. Stick them on a dartboard. Throw something gigantic at the dartboard. Chances are every language you hit conforms to the OO paradigm more closely than perl.

I can write object-oriented assembly. That doesn't make it a particularly OOPy language. Perl objects are hacked on, somewhat painfully at that.

Re:A language that lets you do whatever (0, Flamebait)

guacamole (24270) | about 7 months ago | (#47131183)

This is why Python has become an industry standard language while Perl remains a tool for one-off hacks.

Re:A language that lets you do whatever (1)

preaction (1526109) | about 7 months ago | (#47131289)

Which industry? Finance seems to like Java, C++, and then Python. Web seems to like JavaScript, Ruby, PHP, and then Python. Those are the only industries I have first-hand experience with.

(Though I do recognize the fact that Perl is on none of those lists, even though I'm hired as a Perl programmer in both those industries, I've found it to be one of those things that, like an infection, spreads to every task that needs doing in a unix network)

I think it would be funny as heck if.... (2)

LF11 (18760) | about 7 months ago | (#47129705)

...the Next Great Web Language ends up being PERL? Yes, please.

It has a lot going for it, especially if a project like this makes it as approachable as PHP for web application development.

Serious question, though: other than it being old, are there any problems that keep it from being viable as a modern web application platform?

Re:I think it would be funny as heck if.... (0)

Anonymous Coward | about 7 months ago | (#47129741)

..the Next Great Web Language ends up being PERL? Yes, please.

I'd just be happy if it's not Java (and it's 100's of associated frameworks and XML). Then again I've been doing my web development in C++ with Seminole [gladesoft.com] . Then again that's the great thing about web development: different technologies can be easily combined.

Re:I think it would be funny as heck if.... (0)

Anonymous Coward | about 7 months ago | (#47130357)

Then again I've been doing my web development in C++

Though not common anymore many great websites were C++ powered. Amazon and OkCupid are two that come to mind.

Re:I think it would be funny as heck if.... (0)

Anonymous Coward | about 7 months ago | (#47132077)

I'd just be happy if it's not Java (and it's 100's of associated frameworks and XML).

Don't worry. All of the Perl hate on here will be Java hate in the next 5 years. Things go as quickly as they come in the tech industry. Todays hot technology very quickly becomes tomorrows hated garbage.

Re:I think it would be funny as heck if.... (0)

Anonymous Coward | about 7 months ago | (#47134077)

Doesn't Java already get a lot of hate? If not, it deserves to. What a piece of shit language.

Re:I think it would be funny as heck if.... (1)

Anonymous Coward | about 7 months ago | (#47129971)

Serious question, though: other than it being old, are there any problems that keep it from being viable as a modern web application platform?

Yes. Not technical ones, though. Everyone has been flaming it for so long that it's no longer hip. (Sigh.)

Re:I think it would be funny as heck if.... (3, Interesting)

Anonymous Coward | about 7 months ago | (#47129987)

Yes. Not technical ones, though. Everyone has been flaming it for so long that it's no longer hip. (Sigh.)

The problem is that Perl (like C) requires discipline. It is possible to write well written and architected code in any language. But some languages make it harder than others. But some languages (Java, I'm looking at you) are designed to coddle programmers from doing things they shouldn't. It's silly because engineers should know their craft and not require a nanny in the form of a purposely limited language.

Re:I think it would be funny as heck if.... (2)

larry bagina (561269) | about 7 months ago | (#47130175)

ehh, I tried using perl for a small "modern" (REST) backend, gave up and used ruby/sinatra/mod_passenger because it worked. Perl? Dancer looked nice but there are too many dependencies. CGI is hopelessly obselete (does /. still run on it?). I implemented my own microwebframework on top of CGI (a hundred lines or so to do routing) before I discovered passenger and switched to that.

I'd take perl over node anytime but I'm not impressed by CPAN (it's better than npm, if you want some faint praise) and a lot of the code and culture is stuck in the 80s/90s.

Re:I think it would be funny as heck if.... (0)

Anonymous Coward | about 7 months ago | (#47130209)

CGI is hopelessly obselete (does /. still run on it?).

fastCGI works pretty good and quite a few legacy sites are still running on it. Architecturally it's not all that dissimilar from Apache's mod_jk. I think IMDB [imdb.com] is still using Perl and fastCGI. I have a feeling they get a pretty significant amount of traffic.

Re:I think it would be funny as heck if.... (1)

digsbo (1292334) | about 7 months ago | (#47130461)

Obsolete operationally or for development? I bet I could write a fast website in Assembly, but I couldn't write it quickly. I would not want to do that work I do on a web application today in Perl/CGI. In that sense, it is obsolete.

Re:I think it would be funny as heck if.... (1)

Anonymous Coward | about 7 months ago | (#47131887)

I would not want to do that work I do on a web application today in Perl/CGI. In that sense, it is obsolete.

Everything becomes obsolete. This attitude to me is core to some of the major problems facing technology today: The lack of maintenance. Everything is made with the expectation that it will be in a landfill in two years. But the world can't run that way. Think of how much COBOL code runs your daily life. Rewriting it in a different language would be expensive and provide little value.

So I'm guessing once you complete a project you never have to maintain it? Luck you! I've had customers ask me to change embedded products I've designed 20 years ago. Sometimes the components aren't even available let alone the design tools and technologies. But telling them "no" isn't an option when these things are running city infrastructure.

Re:I think it would be funny as heck if.... (2)

preaction (1526109) | about 7 months ago | (#47130315)

Dancer was inspired by Sinatra, but if you wanted something close to the metal, you wanted Plack (like Rack or WSGI). But really, you wanted Mojolicious.

Dependencies are not a bad thing. CPANTS makes sure they work. But if you don't like dependencies, you wanted Mojolicious.

Re:I think it would be funny as heck if.... (1)

hondo77 (324058) | about 7 months ago | (#47131959)

But really, you wanted Mojolicious.

This.

Re:I think it would be funny as heck if.... (0)

Anonymous Coward | about 7 months ago | (#47130005)

1. Perl is hard to read when programs get above a certain level of complexity. It takes an extraordinary amount of self-control to produce readable Perl, and most programmers simply don't have it.

2. Perl's type model is completely and irrevocably borked:

The string "0" tests to false. However, programmers test strings branches where they're really looking for empty strings or undefined values in their scalar variables. This is a thing that cannot be fixed, and problems involving that error are pervasive.

3. Perl semantics are inscrutable. To find out what actually happens for certain obscure corner cases, one must read the Perl source. Have you ever tried reading the Perl source? It's not easy.

Re:I think it would be funny as heck if.... (2)

preaction (1526109) | about 7 months ago | (#47130223)

1) s/Perl/Code/g

2) This is one of those things that causes frustration the first 3-5 times it happens, and then you find the right habits. I can't remember the last time that actually bit me. Every language has its own definition of falsey.

3) I've never had to read the Perl source to actually solve a problem in my Perl code (except that one time there was an actual bug in Perl, back in 5.10.0). The documentation explains everything, including all the obscure edge and corner cases.

Re:I think it would be funny as heck if.... (0)

Anonymous Coward | about 7 months ago | (#47131287)

1. Perl is particularly bad thanks to the extensive use of magical global variables, implicit variables, dynamic scoping, etc. Those things that let people write more succinct code to their own understanding are not conducive to other's understanding, in particular when reading a bit of code in isolation from it's context.

2. It shows up in production code all the time. The very first page that I find when I Google "perl false" has wrong information on it. If it were at least consistent with the way it coerces strings to numbers, then I could understand. However, strings like "00", "0.0", etc. are not false. Just "0". It makes no fucking sense. Perl's warnings should include something to tell people when they use a scalar variable by itself in a branch.

3. Your anecdotal experience does not constitute proof, and documentation does not constitute formal semantics.

I use the shit out of Perl for small projects, analyzing experimental outputs, etc.. However, it is wholly inadequate for larger projects or projects that I intend other people to see.

Re:I think it would be funny as heck if.... (2)

preaction (1526109) | about 7 months ago | (#47131431)

1) I agree that extensive use of magic vars (the topic var, $_, especially) can create a major problem for readability. But the magic vars, $_ especially, allow concise constructions that would otherwise take a lot of my time to type and longer to verify I typed correctly. The onus is on me, the programmer, to ensure my code is readable, no matter how much the language assists me in that, and I find I can write readable Perl faster than I can write readable JavaScript (choosing two languages I feel I am equally competent in).

2) The rules is the rules, every language has them. "00" isn't false because the rules say only "0" is false. There's even a special case "0 but true" that explicitly does not warn when used in arithmetic operators. This is a necessity due to some of the fundamentals (much like other languages have some crazy constructs due to the interaction/conflict between fundamental concepts). But here, as in 3, you're right: The plural of anecdote (my claim that this does not bite me anymore) is not data.

3) You're right, though you're arguing a technicality. Your next paragraph is also anecdotal: "I find it inadequate" would be accurate, and fully supportable. It is not intrinsically inadequate for large projects, no more than any language is.

Re:I think it would be funny as heck if.... (1)

Camel Pilot (78781) | about 7 months ago | (#47130817)

This is best you can do to flame Perl?

1. It must be me but I do not find Perl any more problematic in this respect than say C or Javascript. In fact facilities like variable string interpolation and symbolic references in my view makes Perl more readable and understandable.

2. So... use if ( defined $str ) what's so irrevocable borked.

3. Care to give an example. I have never read Perl source and have programmed 100k's line of code in Perl and maintain several CPAN modules.

Re:I think it would be funny as heck if.... (0)

Anonymous Coward | about 7 months ago | (#47131403)

Is this the best you can do to defend Perl? I will repeat for you what I said to the other poster. It's funny, since your criticisms are identical -- Perl development must be a real echo chamber:

1. Perl is particularly bad thanks to the extensive use of magical global variables, implicit variables, dynamic scoping, etc. Those things that let people write more succinct code to their own understanding are not conducive to other's understanding, in particular when reading a bit of code in isolation from it's context.

2. It shows up in production code all the time. The very first page that I find when I Google "perl false" has wrong information on it. If it were at least consistent with the way it coerces strings to numbers, then I could understand. However, strings like "00", "0.0", etc. are not false. Just "0". It makes no fucking sense. Perl's warnings should include something to tell people when they use a scalar variable by itself in a branch. If your answer isn't to do the intuitive thing, then there is a serious problem. Somehow you just can't make that connection, though.

3. Your anecdotal experience does not constitute proof, and documentation does not constitute formal semantics. And no, I can't be bothered to give an example because it's been almost a decade since I had to do that last and I can't remember what it was for.

I use the shit out of Perl for small projects, analyzing experimental outputs, etc.. However, it is wholly inadequate for larger projects or projects that I intend other people to see.

Re:I think it would be funny as heck if.... (0)

Anonymous Coward | about 7 months ago | (#47131715)

"00". "0.0" are strings, not booleans.

I really wish Perl had a true boolean so that this notion from C that 0 and 1 represent false and true could be ignored.

Re:I think it would be funny as heck if.... (1)

hondo77 (324058) | about 7 months ago | (#47131995)

NEWS FLASH: Dumbass programmers make dumbass mistakes and produce dumbass code.

Those of us at the adults' table get to use real forks and steak knives and we don't hurt ourselves at all.

Re:I think it would be funny as heck if.... (0)

Anonymous Coward | about 7 months ago | (#47130061)

The ad hoc, implementation-defined syntax and semantics doesn't just make it hard for beginners to read, but it also prevents reimplementations on other architectures.

Languages like Ruby and Python benefit from being available on the JVM or CLR if that's where the rest of your code lives.

Re:I think it would be funny as heck if.... (1)

Anonymous Coward | about 7 months ago | (#47130137)

Languages like Ruby and Python benefit from being available on the JVM or CLR if that's where the rest of your code lives.

Garbage collection is still a huge performance problem. Even with all the modern algorithms the fact that reachable objects must be traced causes real problems with locality of reference. While Perl does have a disgusting syntax the nice thing is it precludes the use of the JVM or CLR. That's probably a good thing.

Disappointing (-1)

Anonymous Coward | about 7 months ago | (#47130219)

Not so much the release, but the gushing fanboiism obscuring the message. It's a good reason not to bother looking at the linked material since apparently it has robbed at least one person of higher brain functions.

Oxymoron (1, Insightful)

canadiannomad (1745008) | about 7 months ago | (#47130601)

Ok, I know I'll get modded down to oblivion for this, but my first thought on reading the headline was "Modern Perl Web Framework, isn't that an oxymoron?" Any others think that as a reflex at first too? Even if you don't really believe it?

I know I used to love Perl, but that was a long time ago...

Re:Oxymoron (5, Interesting)

jjn1056 (85209) | about 7 months ago | (#47131557)

Given I'll make more that $200K programming Perl this year, no that was not my first reflex...

My first reflex on seeing this on Slashdot was, "I probably shouldn't read the article because its going to be filled with the same tired, ignorant Perl hate. And then I'm going to waste time trying to respond to it."

You don't have to use Perl if you don't want to. Why isn't that enough? Why do you feel entitled to dump your FUD on my community? Perl isn't the most popular choice but there's a lot of us making a decent living at it, so please if you don't get it, or you don't like it, unless you have a grudge with Perl that hasn't already been mentioned 100K times what's the point of saying anything at all?

Re:Oxymoron (1)

canadiannomad (1745008) | about 7 months ago | (#47132487)

Why do you feel entitled to dump your FUD on my community?

This wasn't meant as FUD, just good natured jibing. Relax :D

Perl isn't the most popular choice but there's a lot of us making a decent living at it, so please if you don't get it, or you don't like it, unless you have a grudge with Perl that hasn't already been mentioned 100K times what's the point of saying anything at all?

I don't doubt it. I have no hate for Perl, I was joking. Notice how many qualifies I put on my statements? It was just the first thing that popped into my head when I read a slashdot headline, no biggie.

Re:Oxymoron (-1)

Anonymous Coward | about 7 months ago | (#47133599)

"Legacy" jobs often pay the best...

Not trying to be mean, there's so much Perl out there you can ride this right into retirement like the Cobol guys.

We banned Perl (-1)

Anonymous Coward | about 7 months ago | (#47130773)

Way too many vulnerabilities introduced including remote code execution. People just copy + paste some code they found on the Internet or write poor code that results in a heap of vulnerabilities. I'm speaking of using Perl as CGI for a web app.

Re:We banned Perl (1)

preaction (1526109) | about 7 months ago | (#47131213)

Was this during Perl's heyday, when it was ... shudder... popular? The popular language of the day always suffers from very poor programmers making very bad decisions.

Re:We banned Perl (1)

walkeraj (1234310) | about 7 months ago | (#47131509)

I dunno, the authors of Go seem to be making some pretty good decisions so far.

Re:We banned Perl (0)

Anonymous Coward | about 7 months ago | (#47133347)

a) No they're not.
b) (S)he meant programmers using the language, not the language designers.

Re:We banned Perl (1)

hondo77 (324058) | about 7 months ago | (#47132025)

Good choice because, goodness knows, you can only copy/paste Perl...

Re:We banned Perl (0)

Anonymous Coward | about 7 months ago | (#47132189)

If you are too stupid and unskilled to sanitize your input, you shouldn't be coding in ANY language.

Re:We banned Perl (1)

Tanktalus (794810) | about 7 months ago | (#47132607)

Gee, if that was the criteria, I'd be banning Java at work. Because I've seen first-hand a number of Java devs writing absolutely stupid things resulting in a heap of vulnerabilities.

The reality is that you get a bunch of stupid developers, and it doesn't matter what language you put in front of them, they're going to write stupid code. The people who've worked under me in perl don't get the opportunity to write code that dumb because a) I provide a saner framework work in where those gotchas are centralised into common functions and objects, and b) I code review everything that goes in until they acquire a better knowledge base to work from and then I do spot reviews and review anything they feel, with their now better experience, might be tricky and should get extra eyes.

I don't care what language you're working in. If you don't realise that calling the shell with special characters that you didn't know you had will cause problems, it's the developer at fault, not the language. I don't care if it's cmd = "do-stuff " + tainted_value; Process p = java.lang.Runtime.exec(cmd); or my $cmd = "do-stuff $tainted_value"; my $rc = system($cmd);, that's going to result in broken code. If you don't realise that doing the same thing with SQL is going to cause problems, you shouldn't be doing SQL. Or running a subprocess, waiting for it to exit, and THEN reading its stdout. These are all common things, in my experience, and most of them I've seen in Java code, though I do get to work with some nimwits in a different reporting chain using perl stupidly as well. I don't ascribe the bad code to the language, but to the bad developers. Maybe you should look, too, and you'd find it's your developers that are the problem, not the language.

Re:We banned Perl (0)

Anonymous Coward | about 7 months ago | (#47132717)

The bad Java programmers don't wind up publiching to CPAN. The problem is not Perl itself, it's the astonishing array of complete crapware that lives at CPAN is is used without code review by every *new* Perl author. The sort of abuse of sense that occurred in the switchiover from mod_perl version 1 to mod_perl version 2 is happening every day, in dozens of projects, and it's death to stability.

A "new framework" won't fix this taking the "sudo cpan Module::Name" habit of building and installing the latest, unstable, incmpatible crap on the fly is the problem. And a "new framework" won't fix this unless it puts a bullet through the idea of "let's just grab and install the latest!!!" approach to software.

Re:We banned Perl (1)

Tanktalus (794810) | about 7 months ago | (#47132877)

I've put that bullet through that approach.

I've grabbed the precise versions of everything that we're going to use, checked into our version control system, complete with a full build-from-scratch setup that will build perl from source, with the exact options we need (or at least the exact same options every time, not sure if we need threading, for example), and the precise list of CPAN modules that we are using, along with standard patches to said modules where required (some of them don't support AIX as well as we need). Upgrading a module will require a degree of regression testing, etc.. And all developers will use exactly the right levels of everything as the level that is going into production.

I'm a huge fan of CPAN. It has issues, such as some crap code, but yet it remains one of Perl's greatest strengths. Like anything else worth having, it provides sufficient rope to hang yourself with, so you do have to be careful, putting the onus back on the developer to find a mode that works for them. And yet, to fulfill corporate requirements, I'm using precise levels of code. There's no reason why you can't have the best of both worlds.

Re:We banned Perl (0)

Anonymous Coward | about 7 months ago | (#47133717)

Cool, but meanwhile nearly everyone else has solved this problem with some sort of standardized dependency framework, while you are using homebrew glue.

Perl. (1)

vikingpower (768921) | about 7 months ago | (#47131993)

Welcome back into the Middle Age.

Perl Festivity Levels (4, Funny)

TheRealHocusLocus (2319802) | about 7 months ago | (#47133561)

Perl Festivity Level 1: Developers and users have gathered to nibble hors d'oeuvres and chat amiably with each other about the Modern Perl Renaissance. With every sip of their drinks Perl seems ever more striking. Some are gathered around the upright piano improvising songs that proclaim how it is faster, neater, and sharper than ever before with its asynchronous APIs.

Perl Festivity Level 2: Everyone is talking loudly -- sometimes to each other, and sometimes to nobody at all. Perl seems even better. Perl Monks are patiently explaining syntax and style to potted plants and other nearby objects. Around the piano people are feeling fun and flexible, just as programming in scripting languages used to be. Someone is crooning a bawdy ballad where a couple of inexperienced DOM and CSS selectors encounter a very supportive bundled development server.

Perl Festivity Level 3: Monks are arguing violently and defrocking one another over nested do...until loops that bail on exceptions. People are gulping down other peoples' drinks, placing hors d'oeuvres in the upright piano to see what happens when the little hammers strike as everyone bawls "Got my Mojolicious workin' ... but it don't work on Python!" They have lost count of their drinks, and the world is harmonious with blissful adherence to modern interfaces and standards.

Perl Festivity Level 4: All the guests, hors d'oeuvres smeared all over their naked bodies are performing a ritual dance around a burning heap of tables and chairs in celebration of postfix dereference syntax, subroutine signatures, new slice syntax and numerous optimizations. The piano is missing.

~~ with apology and deference to Dave Barry [cmu.edu]

Re:Perl Festivity Levels (0)

Anonymous Coward | about 7 months ago | (#47133731)

A decade too late for the funny points on this shithole, but I laughed.

Post Fix dereferencing about time. (1)

upuv (1201447) | about 7 months ago | (#47134265)

I was very active back in the early days of 5.0 development. I fought for this and lost.

I always struggled with the non-nonsensical @{} ${} ..... style. It was difficult to mentally process. Long chains of dereferencing would be especially complicated.

I'm very pleased to see this finally make it in.

Load More Comments
Slashdot Login

Need an Account?

Forgot your password?