Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask
 
PerlMonks  

Re^5: Thoughts on new 'class' OO in upcoming perl

by haj (Vicar)
on Mar 20, 2023 at 22:01 UTC ( [id://11151088]=note: print w/replies, xml ) Need Help??


in reply to Re^4: Thoughts on new 'class' OO in upcoming perl
in thread Thoughts on new 'class' OO in upcoming perl

Indeed, I guess that this design decision could be a major obstacle for adoption of the new core OO. It is a consequence of the intended encapsulation of classes: Fields without accessors are private to the class, and different classes (and roles) in a class hierarchy can use the same field name without conflicts.

There have been lengthy discussions about allowing subclasses direct access with an explicit "opt-in" mechanism (similar to protected in Java), and I would love to see that. However, this will not happen in the first version of core OO.

  • Comment on Re^5: Thoughts on new 'class' OO in upcoming perl

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (6)
As of 2025-06-13 19:18 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?
    erzuuliAnonymous Monks are no longer allowed to use Super Search, due to an excessive use of this resource by robots.