Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw

Re^4: Why Perl in 2020

by Arunbear (Prior)
on Jan 06, 2021 at 14:58 UTC ( #11126434=note: print w/replies, xml ) Need Help??

in reply to Re^3: Why Perl in 2020
in thread Why Perl in 2020

His claim is correct in the sense that in Python, everything is an object (see an example).

Ironically those objects are hidden behind a procedural skin, no doubt because Python was procedural before OOP was bolted on, and they couldn't have two ways to do the same thing :)

Replies are listed 'Best First'.
Re^5: Why Perl in 2020
by LanX (Sage) on Jan 07, 2021 at 13:25 UTC
      I'm not convinced Python actually has primitives in that sense - at least I'm not aware of any way of distinguishing objects from non-objects (the type function always returns some class or other, unlike it's JS counterpart typeof).
        They could fake it by implicitly bending the method-call operator . much the same way autobox does it with ->

        In the end it's only a question of improving performance.

        Cheers Rolf
        (addicted to the Perl Programming Language :)
        Wikisyntax for the Monastery

Re^5: Why Perl in 2020
by stevieb (Canon) on Jan 06, 2021 at 15:52 UTC

    It would have been prudent of me to have worded it as you have, and that is exactly what I meant... in Python, everything is an object.

Log In?

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

How do I use this? | Other CB clients
Other Users?
Others meditating upon the Monastery: (5)
As of 2021-10-23 20:35 GMT
Find Nodes?
    Voting Booth?
    My first memorable Perl project was:

    Results (88 votes). Check out past polls.