Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

Re^2: perspective and object-disorientation

by adrianh (Chancellor)
on Jan 18, 2003 at 19:04 UTC ( [id://228029]=note: print w/replies, xml ) Need Help??


in reply to Re: perspective and object-disorientation
in thread perspective and object-disorientation

Also, from a code re-entrancy requirement, since changes to @ISA are global, it would be very difficult for two sections of code that had different 'perspectives' to access the same set of objects at the same time.

While I don't think changing @ISA willy-nilly is a good idea, changes are global only if you choose to make them that way.

@ISA can be changed locally using... well... local :-) It can be a useful idiom when testing to make one object temporarily appear as another.

Replies are listed 'Best First'.
Changing @ISA at runtime
by pdcawley (Hermit) on Jan 19, 2003 at 22:39 UTC
    Changing @ISA can be a useful idiom when testing to make one object temporarily appear as another
    But only if you insist on trying to turn Perl into a pessimistically typed language. Us optimistic types just implement the appropriate methods and have done with it. But we've done this discussion already haven't we :)

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others goofing around in the Monastery: (5)
As of 2024-03-28 17:11 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found