Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Re: The Corinna RFC for getting modern OO into the Perl core is taking shape

by hippo (Bishop)
on Aug 20, 2021 at 11:34 UTC ( [id://11135983]=note: print w/replies, xml ) Need Help??


in reply to The Corinna RFC for getting modern OO into the Perl core is taking shape

Damian's excellent blog post includes this comment about Dios:

The only three problems with Dios are:

  • It’s not built-in to Perl itself, so its performance is suboptional;[sic]
  • It’s not built-in to Perl itself, so it requires a huge amount of extremely complex multi-layer code to make it feel as if is;
  • It’s not built-in to Perl itself, so it's merely one possible choice amongst the vast and incoherent array of entirely reasonable alternatives already on CPAN.

While the first 2 problems are objective, the third gives some pause for thought.

As JAPH, I like choice. TIMTOWTDI is as close to being the Perl motto as anything else. There are indeed a plethora of class/object/role systems on CPAN. Probably I've only even heard of half of them, used maybe 5% of them and happily continue to use 1% of them.

The concern here is that if/when a class/object/role system is merged into the language itself, what consequence does this have for all those alternatives on CPAN and all the other code (on CPAN and elsewhere) which depend on them? Will development or maintenance of them cease? Will vast swathes of code have to be rewritten as those modules become unmaintained? The problem is not just with 1% of the modules either because my 1% is highly unlikely to be your 1% which will differ in turn from everybody else's 1%.

Perhaps this has already been debated and determined to be a price worth paying. Perhaps I'm overstating the case. Either way I hope the decision to include any such system in the language itself is not one which we shall come to regret down the line.


🦛

  • Comment on Re: The Corinna RFC for getting modern OO into the Perl core is taking shape

Replies are listed 'Best First'.
Re^2: The Corinna RFC for getting modern OO into the Perl core is taking shape
by mr_mischief (Monsignor) on Aug 23, 2021 at 15:07 UTC

    Corinna isn't being made to disallow Moose or Moo (or Object::InsideOut, Class::Accessor, or whatever else) from working. It's being made to have a sane default in the language that's a bit more modern and more opinionated than blessed data structures and a bit more performant and available than something that sits wholly outside the core.

    Could all the object models on CPAN continue to work without Corinna? Yes. Could they continue to work just the same alongside Corinna? Yes, excepting some might have a keyword collision or two to clear up. Could they embrace Corinna and offer what they choose in addition to what Corinna brings into core? Also, and emphatically, yes.

Re^2: The Corinna RFC for getting modern OO into the Perl core is taking shape
by haj (Vicar) on Aug 20, 2021 at 11:58 UTC
    Will development or maintenance of them cease? Will vast swathes of code have to be rewritten as those modules become unmaintained?

    That's a question for the current maintainers of all these modules to answer, and if they don't want to continue maintaining their modules, to the user base. Modules have become unmaintained for a variety of reasons, and "it's now in the core" is not the most frequent one. If no volunteer is found to step in, then it will still take some years until users must rewrite their code since Perl will always value compatibility.

    And also, it's a loooong way. The first version of Corinna lacks a lot of features which have been added to e.g. Moose or Moo.

    Either way I hope the decision to include any such system in the language itself is not one which we shall come to regret down the line.

    We might regret it if we have the expectation that someone else will, without us paying for that, maintain the modules we want forever. But I hope that we are not like that, otherwise I'd say: we deserve no better.

      It is indeed a long way off. I am still frequently seeing production environments today using 5.16 and occasionally some as far back as 5.8 so there won't be universal coverage of any to-be-introduced language features for well over a decade after release. The consequences of the decision may not be seen for a long time but once the decision is made it will be very difficult to avert them entirely.

      I'm sure that none of us have the expectation of perpetually maintained modules forever, gratis. My concern is that the incentive to maintain an already-widely-used module will likely be reduced if the language is extended to include some/most of the functionality.

      The first version of Corinna lacks a lot of features which have been added to e.g. Moose or Moo.

      Intentionally so - the docs make a big noise about it being an MVP. Perhaps that is all it will ever be: such that to do anything beyond that minimum would require one of the already extant alternatives. That might just be the best of all outcomes.


      🦛

Re^2: The Corinna RFC for getting modern OO into the Perl core is taking shape
by karlgoethebier (Abbot) on Aug 23, 2021 at 09:18 UTC
    «…Will vast swathes of code have to be rewritten as those modules become unmaintained…»

    Sure. This will happen. Because of some visions like this i was very unpopular in the famous last company i was with. See also Cassandra for further details. In German we say: «Ich habe es kommen sehen!» It is like in real life: «They» always tell us that «this» will never happen. But shit happens. Like the tragic flood in Germany recently or the total disaster now in Afghanistan. Regards, Karl

    «The Crux of the Biscuit is the Apostrophe»

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://11135983]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others chanting in the Monastery: (4)
As of 2024-04-19 03:32 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found